I want to combine ggshield(by GitGuardian) and Husky into one pre-commit hook, but the result is that only one of them works.
I tried run pre-commit install
in repo and after this run husky install
in repo. In that case when i tryed to make commit with test errors Husky work but ggshield don't work.
Also after that i tried run git config --unset-all core.hooksPath
for unset git hooks in repo, and run husky install
in repo, and after this run pre-commit install
and received an error: Cowardly refusing to install hooks with 'core.hooksPath' set
.
After this i run git config --unset-all core.hooksPath
and then run pre-commit install
then ggshield will work. But as soon as I run the husky install
command, Husky starts working and ggshield stops working.
It turns out that only one of the git hooks can work at a time? Or is there some way to combine them?