Created
January 7, 2012 19:15
-
-
Save mungomash/1575696 to your computer and use it in GitHub Desktop.
Git cheat sheet
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
# undo a commit (file changes and index changes preserved) | |
git reset --soft HEAD^ | |
# undo a commit (file changes preserved, index changes are rolled back) | |
git reset HEAD^ | |
# undo a commit (file changes and index changes rolled back) | |
git reset --hard HEAD^ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment