Open flugg opened 2 years ago
Hi, please check the tests :) it seems, that something is off
Let me know If I can be of help
I think a custom prepare
/postinstall
script is just the solution, no need to contaminate the current codes.
Of course, a new silent
option is great to me, at least personally.
Hello, great project @toplenboren! Just migrated from Husky myself and have to say this project works in a much more elegant fashion DX-wise.
Inspired by https://github.com/toplenboren/simple-git-hooks/issues/34 I've added built-in support for auto-updating the hooks on commit. It's tested this with both npm and Yarn. In addition, it should not break anything for people who already added the update script to the
pre-commit
hook, but in these cases it will run thesimple-git-hooks
command twice.This all works by running a
simple-git-hooks
command instead of the user-specifiedpre-commit
command. This command uses both asilent
option so the user's terminal isn't bloated with messages when updating the hooks, and anauto
option which executes the configuredpre-commit
.Would love to hear what you think!
Edit: It should probably be mentioned in the release notes/upgrade guide that you need to run the
simple-git-hooks
once with the new version before the automation kicks in.