|
5 | 5 | "main": "dist/index.js",
|
6 | 6 | "types": "dist/index.d.ts",
|
7 | 7 | "scripts": {
|
8 |
| - "test": "echo \"Error: no test specified\" && exit 1", |
| 8 | + "test": "run-s build:noemit", |
9 | 9 | "build": "tsc",
|
| 10 | + "build:noemit": "tsc --noEmit", |
10 | 11 | "postbuild": "npm shrinkwrap",
|
11 | 12 | "docs": "typedoc --options typedoc.json",
|
12 | 13 | "postinstall": "node scripts/not-for-production-warning.js",
|
13 | 14 | "clean": "rimraf ./dist",
|
14 |
| - "prepack": "run-s clean build" |
| 15 | + "prepack": "run-s clean build", |
| 16 | + "lint-staged": "lint-staged", |
| 17 | + "cm": "git-cz", |
| 18 | + "release": "HUSKY_SKIP_HOOKS=1 standard-version", |
| 19 | + "reset-dependencies": "bash ./hooks/update-dependencies" |
15 | 20 | },
|
16 | 21 | "publishConfig": {
|
17 | 22 | "access": "public"
|
|
30 | 35 | "LICENSE"
|
31 | 36 | ],
|
32 | 37 | "devDependencies": {
|
| 38 | + "@commitlint/cli": "^8.0.0", |
| 39 | + "@commitlint/config-conventional": "^8.0.0", |
33 | 40 | "@types/debug": "^4.1.3",
|
34 | 41 | "all-contributors-cli": "^6.7.0",
|
| 42 | + "commitizen": "^3.1.1", |
| 43 | + "cz-conventional-changelog": "^2.1.0", |
| 44 | + "husky": "^3.0.0", |
| 45 | + "lint-staged": "^8.2.1", |
35 | 46 | "npm-run-all": "^4.1.5",
|
| 47 | + "prettier": "^1.18.2", |
36 | 48 | "rimraf": "^2.6.3",
|
| 49 | + "standard-version": "^6.0.1", |
37 | 50 | "typedoc": "^0.14.2",
|
38 | 51 | "typedoc-plugin-external-module-name": "^2.0.0",
|
39 | 52 | "typescript": "^3.4.2"
|
|
49 | 62 | "mime-types": "^2.1.22",
|
50 | 63 | "recursive-readdir": "^2.2.2",
|
51 | 64 | "type-fest": "^0.3.0"
|
| 65 | + }, |
| 66 | + "husky": { |
| 67 | + "hooks": { |
| 68 | + "pre-commit": "run-s lint-staged test", |
| 69 | + "prepare-commit-msg": "exec < /dev/tty && git-cz --hook", |
| 70 | + "commit-msg": "commitlint -E HUSKY_GIT_PARAMS", |
| 71 | + "post-checkout": "reset-dependencies", |
| 72 | + "post-merge": "reset-dependencies" |
| 73 | + } |
| 74 | + }, |
| 75 | + "lint-staged": { |
| 76 | + "*.{js,jsx,ts,tsx}": [ |
| 77 | + "prettier --write", |
| 78 | + "git add" |
| 79 | + ] |
| 80 | + }, |
| 81 | + "config": { |
| 82 | + "commitizen": { |
| 83 | + "path": "./node_modules/cz-conventional-changelog" |
| 84 | + } |
52 | 85 | }
|
53 | 86 | }
|
0 commit comments