Undo last commit in Git
From Josh's answer on StackOverflow:
git commit --amend
The git commit manual says that --amend
, unlike some of the other StackOverflow answers, can be used to amend merge commits.
- Next: Syncing with a remote repo in Git
- Previous: Fixing merge conflicts in Git