Files
qdl/commitlint.config.mjs
T
Igor Opaniuk 972b8e5469 ci: enforce commit message formatting in PRs
Malformed commit messages (overlong lines, missing blank line between
subject and body) have slipped through review. Automate the check in
CI so every PR is validated before merge.

Uses commitlint with a Linux kernel-style config: 72-char limit on
subject and body lines, blank-line rules enforced, Conventional
Commits type enforcement disabled.

Signed-off-by: Igor Opaniuk <igor.opaniuk@oss.qualcomm.com>
2026-03-30 12:09:44 -05:00

34 lines
1.0 KiB
JavaScript
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
// Commitlint config tuned for Linux kernel-style commit messages.
//
// Expected format:
// subsystem: short description (max 72 chars)
// <blank line>
// Body text wrapped at 72 chars.
// <blank line>
// Signed-off-by: Name <email>
export default {
rules: {
// Subject line limit (Linux kernel style uses up to 72)
'header-max-length': [2, 'always', 72],
// Body and footer lines wrapped at 72 chars.
// Footer limit is relaxed to 200 to accommodate long Signed-off-by
// addresses without false positives.
'body-max-line-length': [2, 'always', 72],
'footer-max-line-length': [2, 'always', 200],
// Require a blank line between subject and body, and before footers
'body-leading-blank': [2, 'always'],
'footer-leading-blank': [2, 'always'],
// Disable Conventional Commits type rules - this project uses
// Linux kernel–style "subsystem: description" subjects instead.
'type-enum': [0],
'type-case': [0],
'type-empty': [0],
'scope-empty': [0],
'subject-case': [0],
},
};