-
Notifications
You must be signed in to change notification settings - Fork 0
Notes for conventional commits requirements
Rand McKinney edited this page Apr 7, 2025
·
1 revision
Sometimes the conv. commits requirements can bite you. Here are some tips about how to fix things if you accidentally forget to prefix your commit message as required.
If you commited a change, but didn't yet push it up to GitHub, use this command to change the commit message:
git commit --amend
Change the commit message in the text editor.
If you did push the commit up to GitHub, then do the above PLUS:
git push --force-with-lease origin EXAMPLE-BRANCH
The biggest offender for the commit messages is definitely the UI update branch in GitHub. Fix it like this:
git pull
git commit --amend
# Edit the commit message in vim editor and add proper prefix
git push --force