version-bump-prompt
version-bump-prompt copied to clipboard
Integration with husky
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?
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.
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.
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.