Skip to content

Commit 6c0c2fa

Browse files
committed
add husky
1 parent efaa3d7 commit 6c0c2fa

File tree

3 files changed

+12
-1
lines changed

3 files changed

+12
-1
lines changed

.husky/pre-commit

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
#!/usr/bin/env sh
2+
. "$(dirname -- "$0")/_/husky.sh"
3+
4+
yarn lint

package.json

+3-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,8 @@
1010
"watch:client": "concurrently \"webpack --config webpack.server.js && node dist/server.js\" \"webpack --config webpack.react.js --watch\"",
1111
"watch:server": "concurrently \"webpack --config webpack.react.js\" \"webpack --config webpack.server.js --watch && node dist/server.js\"",
1212
"css": "postcss client/assets/tailwind.css -o client/assets/main.css",
13-
"watch": "concurrently \"webpack --config webpack.react.js --watch\" \"webpack --config webpack.server.js --watch && node dist/server.js\""
13+
"watch": "concurrently \"webpack --config webpack.react.js --watch\" \"webpack --config webpack.server.js --watch && node dist/server.js\"",
14+
"prepare": "husky install"
1415
},
1516
"main": "dist/server.js",
1617
"author": "Exortions",
@@ -63,6 +64,7 @@
6364
"eslint-plugin-import": "^2.26.0",
6465
"eslint-plugin-node": "^11.1.0",
6566
"eslint-plugin-prettier": "^4.2.1",
67+
"husky": "^8.0.1",
6668
"jest": "^29.1.2",
6769
"postcss": "^8.4.17",
6870
"postcss-cli": "^10.0.0",

yarn.lock

+5
Original file line numberDiff line numberDiff line change
@@ -3399,6 +3399,11 @@ human-signals@^2.1.0:
33993399
resolved "https://registry.yarnpkg.com/human-signals/-/human-signals-2.1.0.tgz#dc91fcba42e4d06e4abaed33b3e7a3c02f514ea0"
34003400
integrity sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==
34013401

3402+
husky@^8.0.1:
3403+
version "8.0.1"
3404+
resolved "https://registry.yarnpkg.com/husky/-/husky-8.0.1.tgz#511cb3e57de3e3190514ae49ed50f6bc3f50b3e9"
3405+
integrity sha512-xs7/chUH/CKdOCs7Zy0Aev9e/dKOMZf3K1Az1nar3tzlv0jfqnYtu235bstsWTmXOR0EfINrPa97yy4Lz6RiKw==
3406+
34023407
[email protected], iconv-lite@^0.4.24:
34033408
version "0.4.24"
34043409
resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.24.tgz#2022b4b25fbddc21d2f524974a474aafe733908b"

0 commit comments

Comments
 (0)