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
# This snippet allows to use separate databases for specified git branches. | |
# These databases are created automatically as copies of the default database. | |
# It works only with PostgreSQL. | |
# If you use password to connect to your database you should add it to ~/.pgpass file! | |
# Add this to your local settings file. | |
from settings import * | |
import os, shlex, subprocess |
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
tell application "Adium" to go away | |
tell application "Skype" | |
send command "SET USERSTATUS DND" script name "Alfred" | |
end tell |
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
class Widget | |
constructor: (@widget)-> | |
@input.data("example-widget", @) | |
return | |
(($)-> | |
$.fn.exampleWidget = (action, arg)-> | |
@.each(-> | |
$this = $(@) |
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 csv | |
from lxml import etree | |
FIELDS = ( | |
"Ages", | |
"Assessments", | |
"Audiences", | |
"CreatedDate", | |
"Description", |
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
S = """ | |
bisect.bisect_left(range({N}), {x}) | |
""" | |
if __name__ == '__main__': | |
import timeit | |
from matplotlib import pyplot | |
Ns = [] |
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
#!/bin/bash | |
function usage() { | |
cat >&2 <<EOF | |
Usage: $0 qa|dev | |
EOF | |
exit 1 | |
} | |
[ $# -lt 1 ] && usage |
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
#!/bin/env python3 | |
from pathlib import Path | |
import shutil | |
import os | |
PATHS = ( | |
"balena-etcher-electron/Cache", | |
"Code/Cache", | |
"Code/CachedData", |