diff --git a/.husky/install.mjs b/.husky/install.mjs new file mode 100644 index 0000000..8bbc81a --- /dev/null +++ b/.husky/install.mjs @@ -0,0 +1,6 @@ +// Skip Husky install in CI +if (process.env.CI === 'true') { + process.exit(0); +} +const husky = (await import('husky')).default; +husky(); diff --git a/package.json b/package.json index 5b19ea9..47f67d9 100644 --- a/package.json +++ b/package.json @@ -21,7 +21,7 @@ "build": "tsc -p tsconfig.json", "release": "semantic-release", "test": "jest", - "prepare": "husky" + "prepare": "node .husky/install.mjs" }, "dependencies": { "glob": "^7.1.6",