Testing different git hook managers:
- Husky
- 31.1k stars
- written in: node
- must use js package manager to install, not available in brew and doesn't work without node
- seems to be the defacto choice for the JS world
- no parallel execution
- requires a
package.json
in the root of the repo
- quickhook
- 54 stars
- written in: go
- install with brew (via a tap), deb and rpm available
- supports running hooks in parallel
- hooks are stored in .quickhook/ at the root of the repo
- lefthook
- 3.7k stars
- written in: go
- installable with a lot of package managers including npm, gem, brew (without a tap), deb, rpm...
- supports running hooks in parallel
- stores configuration in
lefthook.yml
in the root of the repo - support for passing changed file list into hook
- colors, pretty output message
- Autohook
- stars: 135
- written in: shell
- no system-wide installation needed, just commit autohook.sh to the repo
- no colors
- no parallel hook execution
- hooks go in
hooks/scripts
dir, then get symlinked to ie.hooks/pre-commit/*
- symlinking part feels very awkward
- pre-commit
- 11.7k stars
- written in: python
- seems fairly mature
- installable with brew
- supports running hooks in parallel
- python is annoying
- hooks are configured in
.pre-commit-config.yaml
but the actual scripts live in another repo.
so far unreviewed: