Home Reverting a Commit in GitHub
Post
Cancel

Reverting a Commit in GitHub

Reverting a Commit in GitHub

How to revert a commit and force push in a local repository to remove commit history.

The commit history will also be deleted.

1
2
 git reset --hard <commit id>
 git push -f origin main
This post is licensed under CC BY 4.0 by the author.

Algorithm - Sum until it exceeds n

Forcing a Pull in the Local Repository