Skip to content

Instantly share code, notes, and snippets.

@rendfall
Created May 24, 2016 10:10
Show Gist options
  • Select an option

  • Save rendfall/3e4f98531b16f850880214d54ba4ae55 to your computer and use it in GitHub Desktop.

Select an option

Save rendfall/3e4f98531b16f850880214d54ba4ae55 to your computer and use it in GitHub Desktop.
[GIT] Undo custom bad commit
git checkout <bad-commit>
# ... make your changes ...
git commit --amend -v
git rebase --onto HEAD <bad-commit> <checked-out-branch>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment