Skip to content

Instantly share code, notes, and snippets.

interface RequireContext {
keys(): string[];
(id: string): {};
}
interface RequireFunction {
context: (path: string, deep?: boolean, filter?: RegExp) => RequireContext;
}
declare var require: RequireFunction;
@Sinitca-Aleksandr
Sinitca-Aleksandr / simple_parser.py
Last active July 21, 2023 05:54
Простой многопоточный парсер на Python 3.5
from bs4 import BeautifulSoup
from urllib.request import urlopen
import threading
eMails = []
urls = []
last_urls =[]
def findEmail(url, TTL, mainUrl):
eMail = ''
try:
#Сразу отсеим ссылки на документы pdf
@jasonkeene
jasonkeene / python_scripting.rst
Last active November 14, 2024 11:18
Get started with writing your own python scripts to automate system tasks.

Python for System Admins / Operators

Installing Python

Most Unix/Linux systems come with python pre-installed:

$ python -V
@EvanHahn
EvanHahn / gist:2587465
Last active October 9, 2023 01:26
Caesar shift in JavaScript
/*
JavaScript Caesar shift
by Evan Hahn (evanhahn.com)
"Encrypt" like this:
caesarShift('Attack at dawn!', 12); // Returns "Mffmow mf pmiz!"
And "decrypt" like this: