Skip to content

Commit

Permalink
fix: Run husky on non-CI env only
Browse files Browse the repository at this point in the history
  • Loading branch information
LukaszNowakPL committed Jun 17, 2024
1 parent 51d1a6d commit 6c9eee3
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
6 changes: 6 additions & 0 deletions .husky/install.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
// Skip Husky install in CI
if (process.env.CI === 'true') {
process.exit(0);
}
const husky = (await import('husky')).default;
husky();
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -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",
Expand Down

0 comments on commit 6c9eee3

Please sign in to comment.