core(pre-commit): adding a lint check before commit
This commit is contained in:
parent
537cd03bb5
commit
481a99ac27
2 changed files with 11 additions and 1 deletions
2
.husky/pre-commit
Normal file
2
.husky/pre-commit
Normal file
|
|
@ -0,0 +1,2 @@
|
||||||
|
#!/usr/bin/env sh
|
||||||
|
pnpm lint-staged
|
||||||
|
|
@ -7,11 +7,17 @@
|
||||||
"./icons",
|
"./icons",
|
||||||
"./auth"
|
"./auth"
|
||||||
],
|
],
|
||||||
|
"lint-staged": {
|
||||||
|
"*": [
|
||||||
|
"eslint --fix"
|
||||||
|
]
|
||||||
|
},
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "npm run build --workspaces --if-present",
|
"build": "npm run build --workspaces --if-present",
|
||||||
"fclean": "rimraf \"**/dist\"",
|
"fclean": "rimraf \"**/dist\"",
|
||||||
"clean": "rimraf \"**/node_modules\"",
|
"clean": "rimraf \"**/node_modules\"",
|
||||||
"install-all": "npm install"
|
"install-all": "npm install",
|
||||||
|
"prepare": "husky"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"rimraf": "^5.0.1",
|
"rimraf": "^5.0.1",
|
||||||
|
|
@ -19,6 +25,8 @@
|
||||||
"@typescript-eslint/eslint-plugin": "^8.44.1",
|
"@typescript-eslint/eslint-plugin": "^8.44.1",
|
||||||
"@typescript-eslint/parser": "^8.44.1",
|
"@typescript-eslint/parser": "^8.44.1",
|
||||||
"eslint": "^9.36.0",
|
"eslint": "^9.36.0",
|
||||||
|
"lint-staged": "^16.1.5",
|
||||||
|
"husky": "^9.1.7",
|
||||||
"typescript-eslint": "^8.44.1"
|
"typescript-eslint": "^8.44.1"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue