Skip to content

Instantly share code, notes, and snippets.

@ivanistheone
ivanistheone / samizdat-shell-help.bash
Last active December 17, 2020 22:23 — forked from kovetskiy/samizdat-shell-help.bash
help text for bas script based on ### comment + awk command
#!/bin/bash
###
### my-script — does one thing well
###
### Usage:
### my-script <input> <output>
###
### Options:
### <input> Input file to read.
### <output> Output file to write. Use '-' for stdout.
#!/usr/bin/env python3
import asyncio
import time
import aiohttp
START = time.monotonic()
@Plutor
Plutor / code.py
Last active February 12, 2018 20:13
Fastest posted /r/nfl posts in the last year that linked to tweets
#!/usr/bin/python
import datetime
import json
import re
import requests
import time
USER_AGENT_HEADER = {'User-Agent': 'nfl-fast-tweets/1.0'}
@willurd
willurd / web-servers.md
Last active May 4, 2025 11:11
Big list of http static server one-liners

Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.

Discussion on reddit.

Python 2.x

$ python -m SimpleHTTPServer 8000