in git, linux

Edit the last local Git commit message

When you want to edit the last local commit message:

git commit --amend

Make your changes then save and quit VIM with:

:wq

Or

to re write the whole commit message in single command:

git commit --amend -m "New commit message"

 

Push to branch .