Created
October 10, 2012 04:38
-
-
Save l1x/3863190 to your computer and use it in GitHub Desktop.
Using git checkout to revert to a certain commit hash
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
#http://stackoverflow.com/a/6457473/127508 | |
git checkout 56e05fced -- . | |
git add . | |
git commit -m 'Revert to 56e05fced' | |
And to prove that it worked: | |
git diff 56e05fced |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment