Skip to content

Commit b7421c1

Browse files
committed
chore: use git local hook
1 parent df8bb19 commit b7421c1

File tree

3 files changed

+4
-50
lines changed

3 files changed

+4
-50
lines changed

.githooks/pre-commit

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
#!/bin/sh
2+
npx --no-install lint-staged

package.json

+2-5
Original file line numberDiff line numberDiff line change
@@ -92,11 +92,7 @@
9292
"webpack": "^5.88.2",
9393
"webpack-cli": "^5.1.4",
9494
"webpack-dev-server": "^4.15.1",
95-
"webpack-merge": "^5.9.0",
96-
"yorkie": "^2.0.0"
97-
},
98-
"gitHooks": {
99-
"pre-commit": "lint-staged"
95+
"webpack-merge": "^5.9.0"
10096
},
10197
"license": "MIT",
10298
"lint-staged": {
@@ -116,6 +112,7 @@
116112
"url": "git+https://github.com/intlify/bundle-tools.git"
117113
},
118114
"scripts": {
115+
"prepare": "git config --local core.hooksPath .githooks",
119116
"build": "npm-run-all -s \"build:utils\" \"build:unplugin\"",
120117
"build:utils": "yarn workspace @intlify/bundle-utils build",
121118
"build:rollup": "yarn workspace @intlify/rollup-plugin-vue-i18n build",

yarn.lock

-45
Original file line numberDiff line numberDiff line change
@@ -1281,7 +1281,6 @@ __metadata:
12811281
webpack-cli: ^5.1.4
12821282
webpack-dev-server: ^4.15.1
12831283
webpack-merge: ^5.9.0
1284-
yorkie: ^2.0.0
12851284
languageName: unknown
12861285
linkType: soft
12871286

@@ -4964,13 +4963,6 @@ __metadata:
49644963
languageName: node
49654964
linkType: hard
49664965

4967-
"ci-info@npm:^1.5.0":
4968-
version: 1.6.0
4969-
resolution: "ci-info@npm:1.6.0"
4970-
checksum: dfc058f60c3889793befe77349c3cd1a5452d21bed5ff60cb34382bee7bbdccc5c4c2ff2b77eab8c411c54d84f93963dacf593b9d901b43b93b7ad2a422aa163
4971-
languageName: node
4972-
linkType: hard
4973-
49744966
"ci-info@npm:^3.2.0":
49754967
version: 3.3.0
49764968
resolution: "ci-info@npm:3.3.0"
@@ -7838,17 +7830,6 @@ __metadata:
78387830
languageName: node
78397831
linkType: hard
78407832

7841-
"is-ci@npm:^1.0.10":
7842-
version: 1.2.1
7843-
resolution: "is-ci@npm:1.2.1"
7844-
dependencies:
7845-
ci-info: ^1.5.0
7846-
bin:
7847-
is-ci: bin.js
7848-
checksum: eca06c5626e54ec01be6f9114a8f19b3f571602cfe66458e42ccc42e401e2ebbe1bd3b2fcaa93b5896b9c759e964f3c7f4d9b2d0f4fc4ef5dba78a7c4825e0be
7849-
languageName: node
7850-
linkType: hard
7851-
78527833
"is-core-module@npm:^2.5.0, is-core-module@npm:^2.8.1":
78537834
version: 2.9.0
78547835
resolution: "is-core-module@npm:2.9.0"
@@ -10009,13 +9990,6 @@ __metadata:
100099990
languageName: node
100109991
linkType: hard
100119992

10012-
"normalize-path@npm:^1.0.0":
10013-
version: 1.0.0
10014-
resolution: "normalize-path@npm:1.0.0"
10015-
checksum: b8b66ac272c7bbf63a3e47a050a5570b137c3e5085e410e2a0fffe1ff663e24e53c51364666586bd38f931e357d3cb5760a30e3c2f902a03f84bd7bf06e7f727
10016-
languageName: node
10017-
linkType: hard
10018-
100199993
"normalize-path@npm:^3.0.0, normalize-path@npm:~3.0.0":
100209994
version: 3.0.0
100219995
resolution: "normalize-path@npm:3.0.0"
@@ -12167,13 +12141,6 @@ __metadata:
1216712141
languageName: node
1216812142
linkType: hard
1216912143

12170-
"strip-indent@npm:^2.0.0":
12171-
version: 2.0.0
12172-
resolution: "strip-indent@npm:2.0.0"
12173-
checksum: 7d9080d02ddace616ebbc17846e41d3880cb147e2a81e51142281322ded6b05b230a4fb12c2e5266f62735cf8f5fb9839e55d74799d11f26bcc8c71ca049a0ba
12174-
languageName: node
12175-
linkType: hard
12176-
1217712144
"strip-indent@npm:^3.0.0":
1217812145
version: 3.0.0
1217912146
resolution: "strip-indent@npm:3.0.0"
@@ -14025,15 +13992,3 @@ __metadata:
1402513992
checksum: 2cac84540f65c64ccc1683c267edce396b26b1e931aa429660aefac8fbe0188167b7aee815a3c22fa59a28a58d898d1a2b1825048f834d8d629f4c2a5d443801
1402613993
languageName: node
1402713994
linkType: hard
14028-
14029-
"yorkie@npm:^2.0.0":
14030-
version: 2.0.0
14031-
resolution: "yorkie@npm:2.0.0"
14032-
dependencies:
14033-
execa: ^0.8.0
14034-
is-ci: ^1.0.10
14035-
normalize-path: ^1.0.0
14036-
strip-indent: ^2.0.0
14037-
checksum: 6810adaf6be7b6cc115ed9454e5a4e8e0949deecb107d65dc0c196051e862f04d6394ad12fbef0d51e6c730329992ae98625ba82cba5e34775023ddb6dc921b8
14038-
languageName: node
14039-
linkType: hard

0 commit comments

Comments
 (0)