Reputation: 157
How do I revert my Github Repository on Github to it's previous state?
I had made some change and committed them to github, but now I want to undo those changes on github. How would I do that?
I tried doing git reset --hard 7727c5bfa99
but that ONLY changed the repository on my computer and not on the github website
Upvotes: 4
Views: 17572
Reputation: 2388
After git reset --hard 7727c5bfa99
, you just push the rolled back commit to remote repository(in this case Github repository), using git push <reponame> -f
.
Upvotes: 0