Skip to content
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

feat: add openedx commitlint.config.js #193

Merged
merged 1 commit into from
Feb 9, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 32 additions & 0 deletions commitlint.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
// See: https://commitlint.js.org/#/reference-configuration for details
// on the configuration file
module.exports = {
extends: ['@commitlint/config-conventional'],

rules: {
'type-enum':
[2, 'always', [
'revert', 'feat', 'fix', 'perf', 'docs', 'test', 'build', 'refactor', 'style', 'chore', 'temp', 'ci',
]],

// Default rules we want to suppress. The available list of rules can be
// found in https://commitlint.js.org/#/reference-rules
'body-leading-blank': [0, "always"],
'body-max-line-length': [0, "always"],
'footer-max-line-length': [0, "always"],
'footer-leading-blank': [0, "always"],
'subject-case': [0, "always", []],
'subject-full-stop': [0, "never", '.'],
},

ignores: [
// Allow GitHub revert messages, like:
// Revert "introduce a bug"
// Revert "introduce a bug" (#1234)
message => /^Revert ".*"( \(#\d+\))?/.test(message),

// BTW: commitlint has a built-in list of ignores which are also applied.
// Those include the typical "Merged" messages, so those are implicitly ignored:
// https://github.com/conventional-changelog/commitlint/blob/master/%40commitlint/is-ignored/src/defaults.ts
],
};
Loading