Skip to content

Instantly share code, notes, and snippets.

View jamiehs's full-sized avatar

Jamie Hamel‑Smith jamiehs

View GitHub Profile

Contract Killer

The popular open-source contract for web designers and developers by Stuff & Nonsense

  • Originally published: 23/12/2008
  • Revised date: 15/12/2013
  • Original post

@jamiehs
jamiehs / .bashrc
Created January 3, 2013 19:18 — forked from henrik/.bashrc
# http://henrik.nyh.se/2008/12/git-dirty-prompt
# http://www.simplisticcomplexity.com/2008/03/13/show-your-git-branch-name-in-your-prompt/
# username@Machine ~/dev/dir[master]$ # clean working directory
# username@Machine ~/dev/dir[master*]$ # dirty working directory
function parse_git_dirty {
[[ $(git status 2> /dev/null | tail -n1) != "nothing to commit (working directory clean)" ]] && echo "*"
}
function parse_git_branch {
git branch --no-color 2> /dev/null | sed -e '/^[^*]/d' -e "s/* \(.*\)/[\1$(parse_git_dirty)]/"
@jamiehs
jamiehs / bash.sh
Last active December 11, 2015 23:38 — forked from zufrieden/gist:3163186
#Alias
alias ll="ls -lah"
alias svnup="svn up --ignore-externals"
alias svnst="svn st --ignore-externals"
alias vhosts="subl /etc/apache2/extra/httpd-vhosts.conf ; subl /etc/hosts"
export PATH="/usr/local/mysql/bin:$PATH"
export PATH=/usr/local/bin:$PATH
export SVN_EDITOR="subl -w"
body .lens-tool-kit.sd2-light .slide-source-custom.slide-type-image .sd2-node-caption {
background: gray;
}
@jamiehs
jamiehs / onDOMContentLoaded-01.js
Created June 13, 2013 17:37 — forked from firedfox/onDOMContentLoaded.js
PhantomJS DOM Loaded
const PHANTOM_FUNCTION_PREFIX = '/* PHANTOM_FUNCTION */';
var page = require('webpage').create();
page.onConsoleMessage = function(msg) {
if (msg.indexOf(PHANTOM_FUNCTION_PREFIX) === 0) {
eval('(' + msg + ')()');
} else {
console.log(msg);
}
[color]
ui = true
[alias]
st = status
c = commit -m
a = add
aa= !git add -u && git add . && git status
co = checkout
cob = checkout -b
up = !git fetch origin && git rebase origin/master
@jamiehs
jamiehs / mq.css
Created October 4, 2012 16:00 — forked from chriscoyier/mq.css
Media Query Breakpoints for Retina Displays
@media only screen and (min-width: 320px) {
/* Small screen, non-retina */
}
@media
only screen and (-webkit-min-device-pixel-ratio: 2) and (min-width: 320px),
only screen and ( min--moz-device-pixel-ratio: 2) and (min-width: 320px),
only screen and ( -o-min-device-pixel-ratio: 2/1) and (min-width: 320px),