# Find the previous commit's SHA $ git log $ git reset --hard <commit> # Force a push to GitHub to overwrite commits $ git push -f