-
Notifications
You must be signed in to change notification settings - Fork 53
Add commit-msg-check GitHub Action for Qualcomm projects #262
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
base: development
Are you sure you want to change the base?
Conversation
- Enforces consistent commit message formatting - Validates commit subject presence and character limit - Ensures commit body exists and adheres to word wrap limit - Adds optional blank line check between subject, body and Signed-off-by signature for readability Signed-off-by: Tharun Kumar Merugu <mtharu@qti.qualcomm.com>
86af28d to
45a48de
Compare
| with: | ||
| body-char-limit: 72 | ||
| sub-char-limit: 50 | ||
| check-blank-line: true No newline at end of file |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
missing EoL
quic-ggopal
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me
|
Looks good to me |
| types: [opened, synchronize, reopened] | ||
|
|
||
| jobs: | ||
| check-commits: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
quick suggestion:
I would suggest commit-message-lint as it describes what the job does.
check-commits means a lot to me seeing in a high level view.
| uses: qualcomm/commit-msg-check-action@main | ||
| env: | ||
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
| with: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I’d also recommend adding a required Signed-off-by line in commits.
This helps to maintain consistency across the commits and improves clarity of commit history.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @thiru31 , most open source repos in qualcomm are using this for Signed-off-by checks, which is why i dint add it. Please take a look -> https://probot.github.io/apps/dco
If this is a requirement by most teams and if we would rather have a check that is done in this qualcomm checker, then we can add that too
|
|
||
| steps: | ||
| - name: Run custom commit check | ||
| uses: qualcomm/commit-msg-check-action@main |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also, sorry for all the last minute changes, but I recently created a release tag for this checker instead of using the main branch: https://github.com/qualcomm/commit-msg-check-action/releases/tag/v1.0.0
Please make this 'v1.0.0' instead of 'main', for better stability and to ensure that this checker doesnt break due to any changes in the main branch
|
NOTE: Wont be needing this change since we are planning on adding this checker to qcom-preflight-checks.yml |
|
I strongly recommend not accepting the change here. It's not infrequent when FastRPC messages must include console logs. Adding these checks would make it wery hard to do, as console logs can span behind 72 chars boundary, etc. |
Hi @lumag , this limit for the subject and body word wrap limit can be set by each tech team. It is customizable. Even the blank line check can be toggled to true or false based on the tech teams requirement |
|
Which limits would you suggest for this project, where we can have kernel or userspace logs in the commit messages? |
Description
This pull request introduces a GitHub Action to enforce consistent commit message formatting across Qualcomm projects. The action helps maintain clarity and readability in commit history by validating key aspects of commit messages.
Key Features
Signed-off-bysignatureWhy This Change?
Consistent commit messages improve collaboration, code reviews, and project traceability. This action automates enforcement, reducing manual checks and errors.