Sometimes I accidentally amend the previous commit with the changes I want to make to the one before that, i.e. HEAD~1
. I usually go into rebase interactive mode with git rebase -i
, split the commit into two commits, complete the rebase. Then rebase again to fixup the original commit
Is there a quicker way to do this? Can I just git commit --amend
after I split the commit, adding my amend changes to the staging area before amending?