-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcommitlint.config.js
More file actions
39 lines (38 loc) · 1.35 KB
/
commitlint.config.js
File metadata and controls
39 lines (38 loc) · 1.35 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
/**
* Commitlint configuration for conventional commits
* @see https://commitlint.js.org
*/
export default {
extends: ['@commitlint/config-conventional'],
rules: {
// Enforce conventional commit types
'type-enum': [
2,
'always',
[
'feat', // New feature
'fix', // Bug fix
'docs', // Documentation changes
'style', // Code style changes (formatting, etc.)
'refactor', // Code refactoring
'perf', // Performance improvements
'test', // Adding or updating tests
'build', // Build system or dependencies
'ci', // CI/CD changes
'chore', // Other changes (maintenance, etc.)
'revert', // Revert previous commit
],
],
// Subject case: lowercase
'subject-case': [2, 'never', ['sentence-case', 'start-case', 'pascal-case', 'upper-case']],
// Subject must not end with period
'subject-empty': [2, 'never'],
'subject-full-stop': [2, 'never', '.'],
// Type must be lowercase
'type-case': [2, 'always', 'lower-case'],
// Type must not be empty
'type-empty': [2, 'never'],
// Header max length
'header-max-length': [2, 'always', 100],
},
};