Got behavior, when my pre-push config was declared as:
// package.json
{
...,
"scripts": {
"prepush": "npm test"
},
"husky": {
"hooks": {
"pre-push": "npm run prepush"
}
}
}
After investigation understood, that this was my mistake:
Husky run both husky.hooks.pre-push AND scripts.prepush.
But it was annoying that tests were initiated twice and no warnings/errors were shown about duplicating config declaration.
Got behavior, when my pre-push config was declared as:
After investigation understood, that this was my mistake:
Husky run both
husky.hooks.pre-pushANDscripts.prepush.But it was annoying that tests were initiated twice and no warnings/errors were shown about duplicating config declaration.