Often I want to edit a commit message without having to re-select the file-set from the last commit.
git commit file1.c file2.c
Accidental typo in commit message.
git commit file1.c file2.c --amend
This works, but Id like not to have to re-select the file-set from the original commit, I once accidentally did git commit -a --amend
and added many changes unintentionally.
I know about git rebase -i HEAD~1
then replace pick
with with r
(re-word), but this ends up being a few steps.
Is there a way to re-word the last commit in one step without including any new files?