Replacing an incorrect git commit message29 Aug 2017 - about 1 min to read
If you have committed some code to git (or in the current case, BitBucket) and you have made an error in the commit message (in the current case, referenced the wrong Jira ticket), all is not lost.
To replace the commit message perform the following actions.
git commit -amend
Change the commit message, in my case;
FOO-1234 - fix the bar - add some stuff
FOO-1235 - fix the bar - add some stuff
Then all that is required is to do a
git push --force