feat: add husky, commit linting
This commit is contained in:
parent
6674e6ac22
commit
affd0c0218
3
.commitlintrc
Normal file
3
.commitlintrc
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
{
|
||||||
|
"extends": ["@commitlint/config-conventional"]
|
||||||
|
}
|
||||||
1
.husky/commit-msg
Normal file
1
.husky/commit-msg
Normal file
@ -0,0 +1 @@
|
|||||||
|
npx --no -- commitlint --edit $1
|
||||||
1
.husky/pre-commit
Normal file
1
.husky/pre-commit
Normal file
@ -0,0 +1 @@
|
|||||||
|
npx lint-staged
|
||||||
3
.lintstagedrc
Normal file
3
.lintstagedrc
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
{
|
||||||
|
"*.[j|t]s": "eslint"
|
||||||
|
}
|
||||||
8
.versionrc
Normal file
8
.versionrc
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
{
|
||||||
|
"header": "# ksv741 React Scripts",
|
||||||
|
"releaseCommitMessageFormat": "build: v{{currentTag}}",
|
||||||
|
"types": [
|
||||||
|
{"type": "feat", "section": "🚀 New Features"},
|
||||||
|
{"type": "fix", "section": "\uD83D\uDEE0\uFE0F Bug Fixes"}
|
||||||
|
]
|
||||||
|
}
|
||||||
23
package.json
23
package.json
@ -16,11 +16,10 @@
|
|||||||
"scripts": {
|
"scripts": {
|
||||||
"prepare": "rm -rf dist && tsc && tsc-alias",
|
"prepare": "rm -rf dist && tsc && tsc-alias",
|
||||||
"typecheck": "tsc --noEmit",
|
"typecheck": "tsc --noEmit",
|
||||||
"lint": "eslint --ignore-pattern node_modules --color src"
|
"lint": "eslint --ignore-pattern node_modules --color src",
|
||||||
},
|
"release": "standard-version"
|
||||||
"bin": {
|
|
||||||
"ksv741-react-scripts": "./bin/scripts.js"
|
|
||||||
},
|
},
|
||||||
|
"bin": "./bin/scripts.js",
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">16"
|
"node": ">16"
|
||||||
},
|
},
|
||||||
@ -86,19 +85,25 @@
|
|||||||
"webpack-dev-server": "5.0.0"
|
"webpack-dev-server": "5.0.0"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
|
"@commitlint/cli": "^19.2.1",
|
||||||
|
"@commitlint/config-conventional": "^19.1.0",
|
||||||
"eslint": "8.57.0",
|
"eslint": "8.57.0",
|
||||||
"eslint-config-ksv741": "0.0.1"
|
"eslint-config-ksv741": "0.0.1",
|
||||||
|
"husky": "^9.0.11",
|
||||||
|
"lint-staged": "^15.2.2",
|
||||||
|
"standard-version": "^9.5.0"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"eslint": ">8.0.0",
|
"eslint": ">8.0.0",
|
||||||
"typescript": "^3.6.0"
|
"typescript": "^3.6.0"
|
||||||
},
|
},
|
||||||
"peerDependenciesMeta": {
|
"peerDependenciesMeta": {
|
||||||
"typescript": {
|
|
||||||
"optional": true
|
|
||||||
},
|
|
||||||
"eslint": {
|
"eslint": {
|
||||||
"optional": true
|
"optional": true
|
||||||
|
},
|
||||||
|
"typescript": {
|
||||||
|
"optional": true
|
||||||
}
|
}
|
||||||
}
|
},
|
||||||
|
"packageManager": "yarn@1.22.19"
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user