Git Cheat Sheet Jan 7th, 2012 | Comments # undo a commit (file changes and index changes preserved) git reset --soft HEAD^