Created
November 2, 2018 11:49
-
-
Save bastman/7bc6cd6850fede51abeac70d4e5e9f3e to your computer and use it in GitHub Desktop.
git_revert_to_commit_hash.sh
This file contains hidden or 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
# see: https://gist.github.com/l1x/3863190 | |
#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