alexjoverm / typescript-library-starter

Starter kit with zero-config for building a library in TypeScript, featuring RollupJS, Jest, Prettier, TSLint, Semantic Release, and more!
MIT License
4.37k stars 493 forks source link

`semantic-release-prepare` throws error with new Husky version #251

Closed ncknuna closed 5 years ago

ncknuna commented 6 years ago

Hey folks, first off, thanks so much for making this awesome starter kit; I've been looking for something like this for a while! Overall, everything works great, but I ran into some trouble when running semantic-release-prepare; more specifically, this error:

Error: Cannot find module '/.../node_modules/husky/bin/install'
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:581:15)
    at Function.Module._load (internal/modules/cjs/loader.js:507:25)
    at Function.Module.runMain (internal/modules/cjs/loader.js:742:12)
    at Object.<anonymous> (/.../node_modules/ts-node/src/bin.ts:157:12)
    at Module._compile (internal/modules/cjs/loader.js:689:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)
    at Module.load (internal/modules/cjs/loader.js:599:32)
    at tryModuleLoad (internal/modules/cjs/loader.js:538:12)
    at Function.Module._load (internal/modules/cjs/loader.js:530:3)
    at Function.Module.runMain (internal/modules/cjs/loader.js:742:12)

I suspect this is due to the version bump from Husky 0.x.x to 1.x.x, but this is my first time using Husky, so I'm not positive about that. If you want, I can try to submit a PR after I figure out how to get this working manually :)