We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e9351c0 commit 21bc342Copy full SHA for 21bc342
1 file changed
src/index.ts
@@ -10,6 +10,11 @@ const git = (args: string[]): cp.SpawnSyncReturns<Buffer> =>
10
cp.spawnSync('git', args, { stdio: 'inherit' })
11
12
export function install(dir = '.husky'): void {
13
+ if (process.env.HUSKY === '0') {
14
+ l('HUSKY env variable is set to 0, skipping install')
15
+ return
16
+ }
17
+
18
// Ensure that we're inside a git repository
19
// If git command is not found, status is null and we should return.
20
// That's why status value needs to be checked explicitly.
0 commit comments