@lobehub/commitlint-config 2.0.0-beta.10

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/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2023 LobeHub
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,101 @@
1
+ <a name="readme-top"></a>
2
+
3
+ <div align="center">
4
+
5
+ <img height="120" src="https://registry.npmmirror.com/@lobehub/assets-logo/1.0.0/files/assets/logo-3d.webp">
6
+ <img height="120" src="https://gw.alipayobjects.com/zos/kitchen/qJ3l3EPsdW/split.svg">
7
+ <img height="120" src="https://registry.npmmirror.com/@lobehub/assets-emoji/1.3.0/files/assets/triangular-ruler.webp">
8
+
9
+ <h1>@lobehub/commitlint-config</h1>
10
+
11
+ Commitlint configuration for LobeHub projects
12
+
13
+ [![][npm-release-shield]][npm-release-link]
14
+ [![][npm-downloads-shield]][npm-downloads-link]
15
+ [![][github-license-shield]][github-license-link]
16
+
17
+ </div>
18
+
19
+ ## Features
20
+
21
+ - Gitmoji commit convention
22
+ - Enforces consistent commit message format
23
+ - Compatible with semantic-release
24
+
25
+ ## Installation
26
+
27
+ ```bash
28
+ pnpm add -D @lobehub/commitlint-config @commitlint/cli
29
+ ```
30
+
31
+ ## Usage
32
+
33
+ Create `commitlint.config.js` (or `.commitlintrc.js`) in your project root:
34
+
35
+ ```js
36
+ import config from '@lobehub/commitlint-config';
37
+
38
+ export default config;
39
+ ```
40
+
41
+ Or for CommonJS:
42
+
43
+ ```js
44
+ module.exports = require('@lobehub/commitlint-config').default;
45
+ ```
46
+
47
+ ## Commit Format
48
+
49
+ ```
50
+ :emoji: type(scope): subject
51
+
52
+ body
53
+
54
+ footer
55
+ ```
56
+
57
+ ### Examples
58
+
59
+ ```
60
+ :sparkles: feat(auth): add OAuth2 support
61
+
62
+ Implement OAuth2 authentication flow with Google and GitHub providers.
63
+
64
+ Closes #123
65
+ ```
66
+
67
+ ```
68
+ :bug: fix(api): resolve race condition in data fetching
69
+ ```
70
+
71
+ ```
72
+ :memo: docs: update installation guide
73
+ ```
74
+
75
+ ## Setting Up Git Hooks
76
+
77
+ With Husky:
78
+
79
+ ```bash
80
+ pnpm add -D husky
81
+ pnpm husky init
82
+ echo "pnpm commitlint --edit \$1" > .husky/commit-msg
83
+ ```
84
+
85
+ ## Requirements
86
+
87
+ - Node.js >= 18
88
+ - @commitlint/cli >= 19.0.0
89
+
90
+ ## License
91
+
92
+ MIT © [LobeHub](https://github.com/lobehub)
93
+
94
+ <!-- LINK GROUP -->
95
+
96
+ [github-license-link]: https://github.com/lobehub/lobe-lint/blob/master/LICENSE
97
+ [github-license-shield]: https://img.shields.io/github/license/lobehub/lobe-lint?color=white&labelColor=black&style=flat-square
98
+ [npm-downloads-link]: https://www.npmjs.com/package/@lobehub/commitlint-config
99
+ [npm-downloads-shield]: https://img.shields.io/npm/dt/@lobehub/commitlint-config?labelColor=black&style=flat-square
100
+ [npm-release-link]: https://www.npmjs.com/package/@lobehub/commitlint-config
101
+ [npm-release-shield]: https://img.shields.io/npm/v/@lobehub/commitlint-config?color=369eff&labelColor=black&logo=npm&logoColor=white&style=flat-square
package/dist/index.cjs ADDED
@@ -0,0 +1,14 @@
1
+ "use strict";
2
+
3
+ //#region src/index.ts
4
+ const config = {
5
+ extends: ["gitmoji"],
6
+ rules: {
7
+ "footer-leading-blank": [0, "never"],
8
+ "header-max-length": [0, "never"]
9
+ }
10
+ };
11
+ var src_default = config;
12
+
13
+ //#endregion
14
+ module.exports = src_default;
@@ -0,0 +1,10 @@
1
+ //#region src/index.d.ts
2
+ declare const config: {
3
+ extends: string[];
4
+ rules: {
5
+ 'footer-leading-blank': readonly [0, "never"];
6
+ 'header-max-length': readonly [0, "never"];
7
+ };
8
+ }; //#endregion
9
+ export { config as default };
10
+ //# sourceMappingURL=index.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.cts","names":[],"sources":["../src/index.ts"],"sourcesContent":null,"mappings":";cAAM;EAAA,OAAA,EAML,MAAA,EAAA"}
@@ -0,0 +1,10 @@
1
+ //#region src/index.d.ts
2
+ declare const config: {
3
+ extends: string[];
4
+ rules: {
5
+ 'footer-leading-blank': readonly [0, "never"];
6
+ 'header-max-length': readonly [0, "never"];
7
+ };
8
+ }; //#endregion
9
+ export { config as default };
10
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","names":[],"sources":["../src/index.ts"],"sourcesContent":null,"mappings":";cAAM;EAAA,OAAA,EAML,MAAA,EAAA"}
package/dist/index.js ADDED
@@ -0,0 +1,13 @@
1
+ //#region src/index.ts
2
+ const config = {
3
+ extends: ["gitmoji"],
4
+ rules: {
5
+ "footer-leading-blank": [0, "never"],
6
+ "header-max-length": [0, "never"]
7
+ }
8
+ };
9
+ var src_default = config;
10
+
11
+ //#endregion
12
+ export { src_default as default };
13
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","names":[],"sources":["../src/index.ts"],"sourcesContent":["const config = {\n extends: ['gitmoji'],\n rules: {\n 'footer-leading-blank': [0, 'never'] as const,\n 'header-max-length': [0, 'never'] as const,\n },\n};\n\nexport default config;\n"],"mappings":";AAAA,MAAM,SAAS;CACb,SAAS,CAAC,SAAU;CACpB,OAAO;EACL,wBAAwB,CAAC,GAAG,OAAQ;EACpC,qBAAqB,CAAC,GAAG,OAAQ;CAClC;AACF;AAED,kBAAe"}
package/package.json ADDED
@@ -0,0 +1,48 @@
1
+ {
2
+ "name": "@lobehub/commitlint-config",
3
+ "version": "2.0.0-beta.10",
4
+ "description": "Commitlint configuration for LobeHub projects",
5
+ "homepage": "https://github.com/lobehub/lobe-lint/tree/master/packages/commitlint-config",
6
+ "bugs": {
7
+ "url": "https://github.com/lobehub/lobe-lint/issues/new"
8
+ },
9
+ "repository": {
10
+ "type": "git",
11
+ "url": "https://github.com/lobehub/lobe-lint.git",
12
+ "directory": "packages/commitlint-config"
13
+ },
14
+ "license": "MIT",
15
+ "author": "canisminor1990 <i@canisminor.cc>, Innei <i@innei.in>",
16
+ "type": "module",
17
+ "exports": {
18
+ ".": {
19
+ "types": "./dist/index.d.ts",
20
+ "import": "./dist/index.js",
21
+ "require": "./dist/index.cjs"
22
+ }
23
+ },
24
+ "main": "./dist/index.cjs",
25
+ "module": "./dist/index.js",
26
+ "types": "./dist/index.d.ts",
27
+ "files": [
28
+ "dist"
29
+ ],
30
+ "dependencies": {
31
+ "commitlint-config-gitmoji": "^2.3.1"
32
+ },
33
+ "peerDependencies": {
34
+ "@commitlint/cli": ">=19.0.0"
35
+ },
36
+ "engines": {
37
+ "node": ">=18"
38
+ },
39
+ "publishConfig": {
40
+ "access": "public",
41
+ "registry": "https://registry.npmjs.org"
42
+ },
43
+ "scripts": {
44
+ "build": "tsdown",
45
+ "dev": "tsdown --watch",
46
+ "type-check": "tsc --noEmit"
47
+ }
48
+ }