Print or use the last git commit message

If you want the last commit message (and nothing else):

git log -1 --pretty=%B

You can also add a commit to get the message

git reset HEAD~
git log -1 --pretty=%B HEAD@{1}

And you can reuse a message for the commit.

git commit --reuse-message=HEAD@{1}