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
postgresql92: | |
image: onjin/alpine-postgres:9.2 | |
volumes: | |
- $HOME/.volumes/postgresql92:/var/lib/postgresql/data | |
postgresql93: | |
image: onjin/alpine-postgres:9.3 | |
volumes: |
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
# -*- coding: utf-8 -*- | |
"""Google Authenticator integration example | |
$ pip install otpauth qrcode pillow | |
""" | |
import qrcode | |
from otpauth import OtpAuth | |
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
postgres: | |
image: postgres:9.4 | |
volumes: | |
- ./init.sql:/docker-entrypoint-initdb.d/init.sql |
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
NeoBundle 'chrisgillis/vim-bootstrap3-snippets' | |
NeoBundle 'vim-scripts/todo-txt.vim' | |
NeoBundle 'farseer90718/vim-taskwarrior' | |
NeoBundle 'vim-perl/vim-perl' | |
NeoBundle 'scrooloose/syntastic' |
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 | |
# This script rotates the screen and touchscreen input 90 degrees each time it is called, | |
# by Ruben Barkow: https://gist.github.com/rubo77/daa262e0229f6e398766 | |
#### configuration | |
# find your Touchscreen device with `xinput` | |
TouchscreenDevice='ELAN Touchscreen' | |
screenMatrix=$(xinput --list-props "$TouchscreenDevice" | awk '/Coordinate Transformation Matrix/{print $5$6$7$8$9$10$11$12$NF}') |
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 | |
ID=$(xinput list|grep TouchPad|awk '{print $6}'| cut -d= -f 2) | |
STATE=$(xinput list-props ${ID} |grep 'Device Enabled'| awk '{ print $4}') | |
function do_enable() { | |
xinput enable ${ID} | |
killall notify-osd | |
notify-send 'TouchPad enabled' | |
} |
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
START: [URL …or… mobile OS + app] | |
STEPS: | |
1. [list the exact steps it takes to reproduce the problem] | |
2. [use numbers to show each step in order] | |
3. [include multiple apps if necessary] | |
4. [write it so a 10 year old could reproduce] | |
ACTUAL: [identify the thing that is broken, screenshots help] | |
EXPECTED: [explain what you expected to see] | |
URGENCY: [only for critical production issue reports] | |
Example: |
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 Specification: | |
def __and__(self, other): | |
return And(self, other) | |
def __or__(self, other): | |
return Or(self, other) | |
def __xor__(self, other): | |
return Xor(self, other) |
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 | |
# -*- coding: utf-8 -*- | |
from collections import namedtuple | |
import requests | |
import logging | |
import json | |
import enum | |
class ApiInteraction(enum.Enum): |
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 | |
# -*- coding: utf-8 -*- | |
""" | |
Simple json server. | |
echo '{"data": "some"}' > p1.json | |
python -m jsonserver | |
curl http://localhost:8000/p1 | |
""" |