Tables | Are | Cool |
---|---|---|
col 3 is | right-aligned | $1600 |
col 2 is | centered | $12 |
zebra stripes | are neat | $1 |
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
HISTSIZE=10000 | |
HISTFILESIZE=200000 | |
export PS1='\W || ' | |
alias gs="git status --short --branch" | |
alias gl="git log2" | |
alias gb="git branch2" | |
alias gm="git checkout master" | |
alias gp="git pull" | |
alias cl="clean_terminal.sh" | |
alias oman="helpmanual.py" |
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
[user] | |
email = <your email> | |
name = <your name> | |
[core] | |
editor = vim | |
[push] | |
default = simple | |
[alias] | |
pushf = push --force-with-lease | |
commend = commit --amend --no-edit |
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
""" | |
Launch ipython with a custom namespace and configuration | |
""" | |
from IPython import start_ipython | |
from IPython.terminal.ipapp import load_default_config | |
c = load_default_config() | |
c.TerminalIPythonApp.display_banner = False | |
c.TerminalInteractiveShell.confirm_exit = False |
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
""" | |
Demonstrating of authenticating a webhook from TutorCruncher. | |
This isn't build with any web framework in particular but demonstrates the idea in generic python 3. | |
""" | |
import hashlib | |
import hmac | |
import json | |
SHARED_SECRET = b'this is also the api key' |
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
[Defaults] | |
# Available Keys: | |
os=linux | |
server_host=TFB-server | |
client_host=TFB-client | |
client_identity_file=/home/vagrant/.ssh/id_rsa | |
client_user=vagrant | |
database_host=TFB-database | |
database_identity_file=/home/vagrant/.ssh/id_rsa | |
database_os=linux |
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
dev: | |
py_file: app/main.py |
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
https://pypi.python.org/pypi/aiohttp/json |
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 datetime import datetime | |
from time import sleep | |
from dnslib import DNSLabel, QTYPE, RD, RR | |
from dnslib import A, AAAA, CNAME, MX, NS, SOA, TXT | |
from dnslib.server import DNSServer | |
EPOCH = datetime(1970, 1, 1) | |
SERIAL = int((datetime.utcnow() - EPOCH).total_seconds()) |
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 alpine:3.5 | |
LABEL maintainer "[email protected]" | |
RUN apk --update --no-cache add bash drill && rm -rf /var/cache/apk/* | |
WORKDIR /home/root | |
CMD ["./run.sh"] |