-
-
Notifications
You must be signed in to change notification settings - Fork 693
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(dev): Add pre-commit hook for semantic commit message check #556
fix(dev): Add pre-commit hook for semantic commit message check #556
Conversation
Marked as draft as the rules for PR title validation differ from semantic commit messages, and need alignment. |
The remaining issue has to do with the uppercase requirement is less common AFAIK:
But at least, it is the same |
Sadly, conventional-pre-commit does not seem to allow enforcing the same subject pattern rule, it accepts subjects with both lowercase and uppercase first letter. |
Hi @antonbabenko, do you think it would be acceptable to relax that PR title rule a bit to allow both upper and lower case first letter? I understand that means quite some work as it would require submitting the same change to all repositories under Or should we try and submit a PR to conventional-pre-commit to implement such additional rules? FWIW: all semantic commit message examples at https://www.conventionalcommits.org/ use a lowercase first letter. |
I don't want us to change what has been (or "was") working for a long time. The PR title should be written well (I edit it now), but the commits itself can be anything. |
Let's close this PR. |
At least, we could keep the basic checks to avoid issues like we faced last week: #554 (comment) |
it is the commit message that triggers the semantic release behavior |
I guess using the PR title as the commit message only works when squashing during PR merge, but it does not work when there's a single commit AFAIU. |
Apparently, there's something that can be done to avoid last week's issue:
|
I think I clicked the wrong button last week when merging PR using the GitHub Mobile app. I have just reviewed the settings for this repository to make sure that we always "Squash and merge". Thanks for the follow-up! |
I'm going to lock this pull request because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further. |
This PR adds a pre-commit check using https://github.com/compilerla/conventional-pre-commit to ensure commit messages are valid.
Example usage: