git commit ammend last commit code example Example: ammend last commit git commit --amend # if you want to add a new message git commit --amend -m