-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.commitlintrc.js
52 lines (49 loc) · 1.5 KB
/
.commitlintrc.js
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
40
41
42
43
44
45
46
47
48
49
50
51
52
// Refer [Rules](https://commitlint.js.org/#/reference-rules)
const RuleLevel = {
Disable: 0,
Warn: 1,
Error: 2,
};
module.exports = {
extends: [
'@commitlint/config-conventional', // scoped packages are not prefixed
],
rules: {
// eslint-disable-next-line no-magic-numbers
'header-max-length': [RuleLevel.Error, 'always', 72],
'scope-enum': [
RuleLevel.Error,
'always',
[
'yargs',
'cli',
// type: docs
'README',
// type: ci
'commitlint',
'dependabot',
'release',
// The below scope is used by dependabot
'deps',
'deps-dev',
// The below scope is used by semantic-release
'release',
],
],
},
ignores: [message => message.match(/^.*?: WIP/)],
};
/**
* **build**: Changes that affect the build system or external dependencies (example scopes: gulp, broccoli, npm)
* **chore**
* **ci**: Changes to our CI configuration files and scripts (example scopes: Circle, BrowserStack, SauceLabs)
* **docs**: Documentation only changes
* **feat**: A new feature
* **fix**: A bug fix
* **improvement**
* **perf**: A code change that improves performance
* **refactor**: A code change that neither fixes a bug nor adds a feature
* **revert**: revert: header of reverted commit<br>refs
* **style**: Changes that do not affect the meaning of the code (white-space, formatting, missing semi-colons, etc)
* **test**: Adding missing tests or correcting existing tests
*/