diff --git a/suites/boilerplate/templates/react/.husky/commit-msg b/suites/boilerplate/templates/react/.husky/commit-msg index 5b0b35410a..c69215d30c 100755 --- a/suites/boilerplate/templates/react/.husky/commit-msg +++ b/suites/boilerplate/templates/react/.husky/commit-msg @@ -1,4 +1 @@ -#!/usr/bin/env sh -. "$(dirname -- "$0")/_/husky.sh" - -npx commitlint --edit "${1}" +commitlint --edit "${1}" diff --git a/suites/boilerplate/templates/react/.husky/pre-commit b/suites/boilerplate/templates/react/.husky/pre-commit index d24fdfc601..c27d8893a9 100755 --- a/suites/boilerplate/templates/react/.husky/pre-commit +++ b/suites/boilerplate/templates/react/.husky/pre-commit @@ -1,4 +1 @@ -#!/usr/bin/env sh -. "$(dirname -- "$0")/_/husky.sh" - -npx lint-staged +lint-staged diff --git a/suites/boilerplate/templates/react/package.json.tpl b/suites/boilerplate/templates/react/package.json.tpl index 8e85595aba..0e07b339c7 100644 --- a/suites/boilerplate/templates/react/package.json.tpl +++ b/suites/boilerplate/templates/react/package.json.tpl @@ -11,7 +11,7 @@ "build:watch": "father dev", "docs:build": "dumi build", "docs:preview": "dumi preview", - "prepare": "husky install && dumi setup", + "prepare": "husky && dumi setup", "doctor": "father doctor", "lint": "npm run lint:es && npm run lint:css", "lint:css": "stylelint \"{src,test}/**/*.{css,less}\"", @@ -63,7 +63,7 @@ "dumi": "{{{ version }}}", "eslint": "^8.23.0", "father": "^4.1.0", - "husky": "^8.0.1", + "husky": "^9.1.2", "lint-staged": "^13.0.3", "prettier": "^2.7.1", "prettier-plugin-organize-imports": "^3.0.0", diff --git a/suites/boilerplate/templates/site/.husky/commit-msg b/suites/boilerplate/templates/site/.husky/commit-msg index 5b0b35410a..c69215d30c 100755 --- a/suites/boilerplate/templates/site/.husky/commit-msg +++ b/suites/boilerplate/templates/site/.husky/commit-msg @@ -1,4 +1 @@ -#!/usr/bin/env sh -. "$(dirname -- "$0")/_/husky.sh" - -npx commitlint --edit "${1}" +commitlint --edit "${1}" diff --git a/suites/boilerplate/templates/site/.husky/pre-commit b/suites/boilerplate/templates/site/.husky/pre-commit index d24fdfc601..c27d8893a9 100755 --- a/suites/boilerplate/templates/site/.husky/pre-commit +++ b/suites/boilerplate/templates/site/.husky/pre-commit @@ -1,4 +1 @@ -#!/usr/bin/env sh -. "$(dirname -- "$0")/_/husky.sh" - -npx lint-staged +lint-staged diff --git a/suites/boilerplate/templates/site/package.json.tpl b/suites/boilerplate/templates/site/package.json.tpl index 14dbc7ee02..68bfee8b19 100644 --- a/suites/boilerplate/templates/site/package.json.tpl +++ b/suites/boilerplate/templates/site/package.json.tpl @@ -7,7 +7,7 @@ "dev": "dumi dev", "build": "dumi build", "preview": "dumi preview", - "prepare": "husky install && dumi setup" + "prepare": "husky && dumi setup" }, "authors": [{{#author}} "{{{ author }}}" @@ -27,7 +27,7 @@ "@commitlint/cli": "^17.1.2", "@commitlint/config-conventional": "^17.1.0", "dumi": "{{{version}}}", - "husky": "^8.0.1", + "husky": "^9.1.2", "lint-staged": "^13.0.3", "prettier": "^2.7.1" }