This file contains hidden or 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 | |
# vim: set fileencoding=utf-8 | |
__author__ = 'Filip Noetzel <http://github.com/peritus/>' | |
__url__ = 'http://longurlspleasebot.appspot.com/' | |
import logging | |
import re | |
import urllib2 |
This file contains hidden or 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
me@box ~ $ wget -S -O /dev/null http://github.com/feeds/simonw/commits/djng/master | |
--2010-03-04 08:39:43-- http://github.com/feeds/simonw/commits/djng/master | |
Resolving github.com (github.com)... 207.97.227.239 | |
Connecting to github.com (github.com)|207.97.227.239|:80... connected. | |
HTTP request sent, awaiting response... | |
HTTP/1.1 301 Moved Permanently | |
Server: nginx/0.7.61 | |
Date: Thu, 04 Mar 2010 07:39:42 GMT | |
Content-Type: text/html; charset=utf-8 | |
Connection: keep-alive |
This file contains hidden or 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 | |
. "$(git --exec-path)/git-sh-setup" | |
test -e `git --exec-path`/git-http-backend||die "git-http-backend does not exist, upgrade to git >= 1.6.6" | |
test -d $GIT_DIR/gitweb || die "$GIT_DIR/gitweb does not exist, try running 'git instaweb -d webrick'" | |
test -e $GIT_DIR/gitweb/webrick || die "$GIT_DIR/gitweb/webrick does not exist, try running 'git instaweb -d webrick'" | |
GIT_BIN=`git --exec-path`/git | |
CGI_NAME=`basename \`pwd\``.cgi |
This file contains hidden or 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
" disable cursor keys to train Filip's muscular memory | |
noremap <Up> "" | |
noremap! <Up> <Esc> | |
noremap <Down> "" | |
noremap! <Down> <Esc> | |
noremap <Left> "" | |
noremap! <Left> <Esc> | |
noremap <Right> "" | |
noremap! <Right> <Esc> |
This file contains hidden or 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
[alias] | |
st = status -uall | |
sts = status -uall -sb | |
d = diff | |
puff = pull --ff-only | |
dw = diff --color-words | |
dc = diff --cached | |
dcw = diff --cached --color-words | |
lg = log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %Cblue<%an>%Creset' --abbrev-commit --date=relative | |
log1 = log --pretty=oneline --abbrev-commit --decorate |
This file contains hidden or 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
# Vagrant Rsync Provisioner | |
# | |
# TODO: Make the download commands available via 'vagrant rsync_download' | |
# | |
# == Motivation == | |
# | |
# I want to 'vagrant destroy' and 'vagrant up' vms when on the train, plane and | |
# bus. Not fetching debian packages also tends to make provisioning with chef | |
# faster. | |
# |
This file contains hidden or 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 ruby | |
# MOOCROP | |
# | |
# Results: http://ueberredungskunst.aadabay.com/moo-minicards | |
# | |
# Creates detail views of high-resolution photos suitable for creating moocards | |
# Slices in variations of top-left corner and scale | |
# | |
# Results after first order (used http://aadabay.com/ paintings: WOW!) |
This file contains hidden or 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/sh -e | |
# BOTTOM LINE: | |
# | |
# You have to call `git update-index --refresh` before calling | |
# `git describe` or the dirty flag might be inaccurate. | |
# Discussion: | |
# https://twitter.com/peritus/status/61361229876314112 | |
# https://twitter.com/artagnon/status/61471028567752704 |
This file contains hidden or 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 script shuts down my AWS EC2 hosted Jenkins if | |
# there were no builds in the last hour. | |
# | |
# Set this script to run as build step in jenkins every minute like this | |
# | |
# [x] Build periodically | |
# | |
# Schedule * * * * * | |
# |
This file contains hidden or 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
function(doc) { | |
// stolen from | |
// https://github.com/sstephenson/prototype/blob/master/src/prototype/lang/object.js#L88 | |
function extend(destination, source) { | |
for (var property in source) | |
destination[property] = source[property]; | |
return destination; | |
} | |
var copy = extend({}, doc); |
OlderNewer