Removing a file from git history

BE VERY CAREFUL!

This will go through ALL of your commits and remove all references to your big file you accidentally committed way back.

1. Go to your repository in terminal.
2. paste this line in, but substitute bigfile.psd to whatever you want to remove.

git filter-branch --index-filter 'git rm -rf --cached --ignore-unmatch bigfile.psd’ -- --all

Source: http://dangodesign.net/2014/02/remove-large-file-git/