From 4e962f3e2233c21ce37310b9c54cbf10272f2193 Mon Sep 17 00:00:00 2001 From: Peter Muessig Date: Tue, 3 Sep 2024 08:11:52 +0300 Subject: [PATCH] chore: keep using own husky switch --- .husky/skip.js | 5 +++++ package.json | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) create mode 100644 .husky/skip.js diff --git a/.husky/skip.js b/.husky/skip.js new file mode 100644 index 0000000..3310088 --- /dev/null +++ b/.husky/skip.js @@ -0,0 +1,5 @@ +if (process.env.HUSKY_SKIP || process.env.NODE_ENV === "production") { + process.exit(0); +} else { + process.exit(1); +} diff --git a/package.json b/package.json index 274116f..7744bbd 100644 --- a/package.json +++ b/package.json @@ -24,7 +24,7 @@ "lint:staged": "lint-staged", "format": "prettier --write .", "format:staged": "pretty-quick --staged --verbose", - "prepare": "husky", + "prepare": "node ./.husky/skip.js || husky", "hooks:commit-msg": "commitlint -e", "hooks:pre-commit": "npm run format:staged && npm run lint:staged" },