View gist:391efbab004bbe6f8643a7e44713e2c0
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
git checkout master | |
git fetch | |
git remote prune origin | |
git branch --merged master | grep -v 'master$' | xargs git branch -d | |
git branch -r --merged master | sed 's/ *origin\///' | grep -v 'master$' | |
read -p "Continue (y/n)? " | |
if [ "$REPLY" == "y" ] | |
then | |
git branch -r --merged master | sed 's/ *origin\///' | grep -v 'master$' | xargs -I% git push origin :% |
View clone-all-github-repos.sh
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
curl -u <token>:x-oauth-basic -s https://api.github.com/orgs/<repo-name>/repos\?per_page\=200 | ruby -rubygems -e 'require "json"; JSON.load(STDIN.read).each { |repo| %x[git clone #{repo["ssh_url"]} ]}' |
View mirror_cheater.sh
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 | |
# define $SHELL_VARS here | |
report_error () { | |
MESSAGE=$1 | |
SUBJECT=$2 | |
echo "$MESSAGE" | $MAILPROGRAM --subject="$SUBJECT" --toList=$EMAIL | |
} |
View gist:4d68713fc7ad99c5799c
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
### Keybase proof | |
I hereby claim: | |
* I am holodigm on github. | |
* I am kym (https://keybase.io/kym) on keybase. | |
* I have a public key whose fingerprint is 6EB4 041C 7221 4C8E E8CD A12A 8AEF B958 3B45 D31B | |
To claim this, I am signing this object: |
View gist:b1bba0ddc84754753c5c
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
apt-add-repository ppa:brightbox/ruby-ng | |
apt-get update | |
apt-get install python-software-properties -y | |
apt-get install ruby rubygems ruby-switch ruby2.1 ruby2.1-dev -y | |
ruby-switch --set ruby2.1 | |
gem install bundler | |
ruby -v | |
apt-get purge nginx* -y | |
echo "deb http://nginx.org/packages/ubuntu/ precise nginx" >> /etc/apt/sources.list |
View gist:11391921
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
apt-get install python-software-properties | |
apt-add-repository ppa:brightbox/ruby-ng | |
apt-get update | |
apt-get install ruby rubygems ruby-switch ruby2.1 ruby2.1-dev -y | |
ruby-switch --set ruby2.1 | |
gem install bundler |
View gist:3949756
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 ApplicationController < ActionController::Base | |
... | |
# FORCE to implement content_for in controller | |
def view_context | |
super.tap do |view| | |
(@_content_for || {}).each do |name,content| | |
view.content_for name, content | |
end | |
end | |
end |