Skip to content

Allowed more "ref" lines in commit messages#28261

Open
EvanHahn wants to merge 1 commit into
mainfrom
update-commit-ref-check
Open

Allowed more "ref" lines in commit messages#28261
EvanHahn wants to merge 1 commit into
mainfrom
update-commit-ref-check

Conversation

@EvanHahn
Copy link
Copy Markdown
Contributor

no ref

This change should have no user impact. It just quiets a development-only warning.

Before this change, our pre-commit hook showed a warning unless your commit's third line started with "ref", "fixes", or "closes".

Now it supports a wide array of options. These are lifted from some our internal document, "How to write commit messages".

no ref

This change should have no user impact. It just quiets a
development-only warning.

Before this change, our pre-commit hook showed a warning unless your
commit's third line started with "ref", "fixes", or "closes".

Now it supports a wide array of options. These are lifted from some
our internal document, "How to write commit messages".
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented May 29, 2026

Review Change Stack

Walkthrough

This PR updates the commit-msg validation hook to accept a broader set of issue-link keywords on the third line of commit messages. The validation regex is expanded to recognize ref, close, fixes, related to, contributes to, and no ref notations instead of a limited set. The error message and validation warning text are updated to reflect this wider keyword support.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately describes the main change: expanding the set of allowed 'ref' keywords in commit message validation.
Description check ✅ Passed The description is directly related to the changeset, explaining the motivation and nature of the commit-msg hook update.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch update-commit-ref-check

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

coderabbitai[bot]

This comment was marked as resolved.

@EvanHahn EvanHahn requested a review from troyciesco May 30, 2026 20:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant