Skip to content

Commit c362eca

Browse files
committed
Add githooks
1 parent 3bfc4f2 commit c362eca

File tree

2 files changed

+33
-3
lines changed

2 files changed

+33
-3
lines changed

package.json

+6-3
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,10 @@
99
"scripts": {
1010
"test": "mocha --timeout 10000 test/*.test.js",
1111
"watch:test": "mocha --timeout 10000 --watch test/*.test.js",
12-
"test:cover" : "nyc npm run test",
13-
"cover:lcovonly": "nyc report --reporter=lcovonly"
12+
"test:cover": "nyc npm run test",
13+
"cover:lcovonly": "nyc report --reporter=lcovonly",
14+
"precommit" : "npm run test:cover",
15+
"prepush" : "npm run test:cover"
1416
},
1517
"keywords": [
1618
"webpack",
@@ -31,6 +33,7 @@
3133
"chai": "^3.5.0",
3234
"css-loader": "^0.27.3",
3335
"extract-text-webpack-plugin": "^2.1.0",
36+
"husky": "^0.13.3",
3437
"mocha": "^3.2.0",
3538
"nyc": "^10.2.0",
3639
"rimraf": "^2.6.1",
@@ -45,7 +48,7 @@
4548
"include": [
4649
"src/**.js"
4750
],
48-
"reporter" : [
51+
"reporter": [
4952
"text",
5053
"lcov"
5154
],

yarn.lock

+27
Original file line numberDiff line numberDiff line change
@@ -457,6 +457,10 @@ chokidar@^1.4.3:
457457
optionalDependencies:
458458
fsevents "^1.0.0"
459459

460+
ci-info@^1.0.0:
461+
version "1.0.0"
462+
resolved "https://registry.yarnpkg.com/ci-info/-/ci-info-1.0.0.tgz#dc5285f2b4e251821683681c381c3388f46ec534"
463+
460464
cipher-base@^1.0.0, cipher-base@^1.0.1:
461465
version "1.0.3"
462466
resolved "https://registry.yarnpkg.com/cipher-base/-/cipher-base-1.0.3.tgz#eeabf194419ce900da3018c207d212f2a6df0a07"
@@ -932,6 +936,10 @@ find-cache-dir@^0.1.1:
932936
mkdirp "^0.5.1"
933937
pkg-dir "^1.0.0"
934938

939+
find-parent-dir@^0.3.0:
940+
version "0.3.0"
941+
resolved "https://registry.yarnpkg.com/find-parent-dir/-/find-parent-dir-0.3.0.tgz#33c44b429ab2b2f0646299c5f9f718f376ff8d54"
942+
935943
find-up@^1.0.0, find-up@^1.1.2:
936944
version "1.1.2"
937945
resolved "https://registry.yarnpkg.com/find-up/-/find-up-1.1.2.tgz#6b2e9822b1a2ce0a60ab64d610eccad53cb24d0f"
@@ -1166,6 +1174,15 @@ https-browserify@0.0.1:
11661174
version "0.0.1"
11671175
resolved "https://registry.yarnpkg.com/https-browserify/-/https-browserify-0.0.1.tgz#3f91365cabe60b77ed0ebba24b454e3e09d95a82"
11681176

1177+
husky@^0.13.3:
1178+
version "0.13.3"
1179+
resolved "https://registry.yarnpkg.com/husky/-/husky-0.13.3.tgz#bc2066080badc8b8fe3516e881f5bc68a57052ff"
1180+
dependencies:
1181+
chalk "^1.1.3"
1182+
find-parent-dir "^0.3.0"
1183+
is-ci "^1.0.9"
1184+
normalize-path "^1.0.0"
1185+
11691186
icss-replace-symbols@^1.0.2:
11701187
version "1.0.2"
11711188
resolved "https://registry.yarnpkg.com/icss-replace-symbols/-/icss-replace-symbols-1.0.2.tgz#cb0b6054eb3af6edc9ab1d62d01933e2d4c8bfa5"
@@ -1239,6 +1256,12 @@ is-builtin-module@^1.0.0:
12391256
dependencies:
12401257
builtin-modules "^1.0.0"
12411258

1259+
is-ci@^1.0.9:
1260+
version "1.0.10"
1261+
resolved "https://registry.yarnpkg.com/is-ci/-/is-ci-1.0.10.tgz#f739336b2632365061a9d48270cd56ae3369318e"
1262+
dependencies:
1263+
ci-info "^1.0.0"
1264+
12421265
is-dotfile@^1.0.0:
12431266
version "1.0.2"
12441267
resolved "https://registry.yarnpkg.com/is-dotfile/-/is-dotfile-1.0.2.tgz#2c132383f39199f8edc268ca01b9b007d205cc4d"
@@ -1746,6 +1769,10 @@ normalize-package-data@^2.3.2:
17461769
semver "2 || 3 || 4 || 5"
17471770
validate-npm-package-license "^3.0.1"
17481771

1772+
normalize-path@^1.0.0:
1773+
version "1.0.0"
1774+
resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-1.0.0.tgz#32d0e472f91ff345701c15a8311018d3b0a90379"
1775+
17491776
normalize-path@^2.0.1:
17501777
version "2.1.1"
17511778
resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-2.1.1.tgz#1ab28b556e198363a8c1a6f7e6fa20137fe6aed9"

0 commit comments

Comments
 (0)