This is based on Zach Holman's great "@holman does dotfiles". You might want to read the original post on the subject by Zach Holman.
To install, run this:
git clone https://github.com/mixmaster/dotfiles.git ~/.dotfiles
cd ~/.dotfiles
git submodule init
git submodule update
script/bootstrap