@map-colonies/commitlint-config 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +20 -0
- package/index.js +9 -0
- package/package.json +53 -0
package/README.md
ADDED
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# commitlint-config
|
|
2
|
+
Common commitlint configuration for MapColonies projects
|
|
3
|
+
|
|
4
|
+
## Installation
|
|
5
|
+
To install the package run the following command:
|
|
6
|
+
```bash
|
|
7
|
+
npm install --save-dev @mapcolonies/commitlint-config
|
|
8
|
+
```
|
|
9
|
+
|
|
10
|
+
## Usage
|
|
11
|
+
To use the package, create a `commitlint.config.js` file in the root of your project and add the following code:
|
|
12
|
+
```javascript
|
|
13
|
+
module.exports = {
|
|
14
|
+
extends: ['@mapcolonies/commitlint-config'],
|
|
15
|
+
};
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
## Rules
|
|
19
|
+
This package extends all the rules from the `@commitlint/config-conventional` package and adds the following rules:
|
|
20
|
+
1. The allowed values for the type parameters (feat,fix,chore..) are as follow: `deps`, `helm`, `build`, `chore`, `ci`, `docs`, `feat`, `fix`, `perf`, `refactor`, `revert`, `style`, `test`
|
package/index.js
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @type {import('@commitlint/types').UserConfig}
|
|
3
|
+
*/
|
|
4
|
+
module.exports = {
|
|
5
|
+
extends: ['@commitlint/config-conventional'],
|
|
6
|
+
rules: {
|
|
7
|
+
'type-enum': [2, 'always', ['deps', 'helm', 'build', 'chore', 'ci', 'docs', 'feat', 'fix', 'perf', 'refactor', 'revert', 'style', 'test']],
|
|
8
|
+
},
|
|
9
|
+
};
|
package/package.json
ADDED
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@map-colonies/commitlint-config",
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"description": "Commitlint configuration for MapColonies projects",
|
|
5
|
+
"main": "./index.js",
|
|
6
|
+
"exports": {
|
|
7
|
+
".": {
|
|
8
|
+
"require": "./index.js"
|
|
9
|
+
}
|
|
10
|
+
},
|
|
11
|
+
"scripts": {
|
|
12
|
+
"test": "jest --config=./tests/configurations/jest.config.js",
|
|
13
|
+
"format": "prettier --check .",
|
|
14
|
+
"format:fix": "prettier --write .",
|
|
15
|
+
"clean": "rimraf dist",
|
|
16
|
+
"prepare": "husky"
|
|
17
|
+
},
|
|
18
|
+
"repository": {
|
|
19
|
+
"type": "git",
|
|
20
|
+
"url": "git+https://github.com/MapColonies/commitlint-config.git"
|
|
21
|
+
},
|
|
22
|
+
"author": "MapColonies",
|
|
23
|
+
"license": "ISC",
|
|
24
|
+
"bugs": {
|
|
25
|
+
"url": "https://github.com/MapColonies/commitlint-config/issues"
|
|
26
|
+
},
|
|
27
|
+
"files": [
|
|
28
|
+
"index.js"
|
|
29
|
+
],
|
|
30
|
+
"homepage": "https://github.com/MapColonies/commitlint-config#readme",
|
|
31
|
+
"publishConfig": {
|
|
32
|
+
"access": "public"
|
|
33
|
+
},
|
|
34
|
+
"engines": {
|
|
35
|
+
"node": ">=20"
|
|
36
|
+
},
|
|
37
|
+
"dependencies": {
|
|
38
|
+
"@commitlint/config-conventional": "^19.6.0"
|
|
39
|
+
},
|
|
40
|
+
"devDependencies": {
|
|
41
|
+
"@commitlint/cli": "^19.6.1",
|
|
42
|
+
"@map-colonies/prettier-config": "^0.0.1",
|
|
43
|
+
"@types/jest": "^29.4.0",
|
|
44
|
+
"commitlint": "^19.6.1",
|
|
45
|
+
"husky": "^9.1.7",
|
|
46
|
+
"jest": "^29.7.0",
|
|
47
|
+
"jest-html-reporters": "^3.1.4",
|
|
48
|
+
"prettier": "^3.4.2",
|
|
49
|
+
"pretty-quick": "^4.0.0",
|
|
50
|
+
"@commitlint/types": "^19.5.0",
|
|
51
|
+
"zx": "^8.3.0"
|
|
52
|
+
}
|
|
53
|
+
}
|