Skip to content

Commit

Permalink
fix: init create dir before
Browse files Browse the repository at this point in the history
  • Loading branch information
typicode committed Jan 25, 2024
1 parent 417568d commit 2033052
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions bin.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ if (a == 'init') {
d.scripts.prepare = 'husky'
w('package.json', JSON.stringify(d, null, /\t/.test() ? '\t' : 2) + '\n')
process.stdout.write(i())
try { f.mkdirSync('.husky') } catch {}
w('.husky/pre-commit', process.env.npm_config_user_agent.split('/')[0] + ' test\n')
process.exit()
}
Expand Down

0 comments on commit 2033052

Please sign in to comment.