This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
# -*- mode: python; coding: utf-8 -*- | |
assert str is not bytes | |
import sys | |
def main(): | |
if len(sys.argv) not in (3, 4): | |
print('usage: {} <keyword> <path> [final_keyword]'.format(sys.argv[0]), file=sys.stderr) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
# -*- mode: python; coding: utf-8 -*- | |
assert str is not bytes | |
import sys, os, os.path | |
def del_prefix(s, prefix): | |
assert isinstance(s, str) | |
assert isinstance(prefix, str) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- mode: sh; coding: utf-8 -*- | |
milanta_pict_conv__pict_conv () { | |
ico_width="160" | |
ico_height="120" | |
in_path="$1" | |
in_basename="$(basename -- "$in_path")" | |
in_name="${in_basename%\.*}" | |
in_dir="$(dirname -- "$in_path")" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/bash | |
out_file="decode-out.txt" | |
decode_filter="$(dirname -- "$0")/siemens-qu-pr-decode" | |
echo "# $(date)" >"$out_file" | |
for arg | |
do | |
echo "--------------------------------------------------">>"$out_file" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
# -*- mode: python; coding: utf-8 -*- | |
# | |
# ОПИСАНИЕ: | |
# | |
# скрипт который должен создать "директорию-убийцу"! | |
# | |
# это такая *пустая* директория, некоторые операции внутри которой | |
# будут производиться очень медленно. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# see: https://gist.github.com/4686149/f5f6b978b01d886d3e5d5979208247d25202195e | |
# | |
{'messages': None, | |
'result': [{'building_number': 'б', | |
'city': 'Пенза', | |
'city_id': '238', | |
'geo_point_id': '44803', | |
'hotspot_about': '', | |
'hotspot_name': 'Иномарка, магазин', | |
'hotspot_phone': '', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ curl -S -H "Referer: http://any-stupid-domain/any-stupid-path/domru.ru/wifi" http://penza.domru.ru/wifi/getPoints ; echo ; date | |
{ "success": 1, "result": [ { "pid": "40045", "geo_point_id": "44803", "city_id": "238", "city": "\u041f\u0435\u043d\u0437\u0430", "street": "\u043f\u0440\u043e\u0441\u043f\u0435\u043a\u0442 \u0421\u0442\u0440\u043e\u0438\u0442\u0435\u043b\u0435\u0439", "house_number": "16", "building_number": "\u0431", "latitude": "53.219565", "longitude": "44.936776", "hotspot_type_id": "2", "hotspot_type": "\u0410\u0432\u0442\u043e\u043c\u043e\u0431\u0438\u043b\u0438", "hotspot_name": "\u0418\u043d\u043e\u043c\u0430\u0440\u043a\u0430, \u043c\u0430\u0433\u0430\u0437\u0438\u043d", "hotspot_about": "", "hotspot_phone": "", "hotspot_website": "", "hotspot_worktime": "\u041a\u0440\u0443\u0433\u043b\u043e\u0441\u0443\u0442\u043e\u0447\u043d\u043e", "hotspot_rating": "0", "vlan": "202:3604" }, { "pid": "40038", "geo_point_id": "41528", "city_id": "238", "city": "\u041f\u0435\u043d\u0437\u0430", "street |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- mode: python; coding: utf-8 -*- | |
# | |
# Copyright 2012 Andrej A Antonov <[email protected]>. | |
# | |
# This program is free software: you can redistribute it and/or modify | |
# it under the terms of the GNU Lesser General Public License as published by | |
# the Free Software Foundation, either version 3 of the License, or | |
# (at your option) any later version. | |
# | |
# This program is distributed in the hope that it will be useful, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
# -*- mode: python; coding: utf-8 -*- | |
assert str is not bytes | |
import sys | |
import csv | |
def main(): | |
for arg in sys.argv[1:]: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# -*- mode: python; coding: utf-8 -*- | |
from __future__ import absolute_import | |
import random, itertools | |
from twisted.internet import reactor, protocol, defer | |
from twisted.web import client, http_headers | |
# ********** BEGIN CONFIGURE CONSTANTS ********** |