version-bump-prompt icon indicating copy to clipboard operation
version-bump-prompt copied to clipboard

Integration with husky

Open chimilord opened this issue 4 years ago • 3 comments

I have the following configuration in my package.json:

{
  "husky": {
    "hooks": {
      "pre-commit": "npm run lint && npm run bump",
    }
  }
...

The bump-prompt is opened and asks me for the version but does not let me choose and returns to my console. Exists some way to integrate with husky hooks?

chimilord avatar Apr 07 '20 02:04 chimilord

This may be a limitation of Husky. Perhaps it doesn't support tools that prompt for user input. Or perhaps there's something you need to configure in Husky to make it work. Either way, I suggest opening an issue on the Husky repo.

JamesMessinger avatar Apr 07 '20 09:04 JamesMessinger

Similarly, on the other way around, bumping with --commit, will run husky, but gets exited immediately, so only package.json is bumped, no commit, no push.

DiegoRBaquero avatar Feb 16 '21 22:02 DiegoRBaquero

This happens also when using a github pre-commit hook as well, where the prompt appears but exits before you have chance to action anything.

gregoryduckworth avatar Sep 03 '21 15:09 gregoryduckworth