> - git-multi-hook https://www.codeofhonor.com/projects/git-multi-hook/ git only allows one script per hook event; this is a dispatcher that discovers and runs every script in a hooks dir, in parallel, for both global and repo hooks.
Here's what gemini says about running hooks in parallel:
> Native Git traditionally executes hooks sequentially. However, you can achieve parallel execution by leveraging dedicated third-party hook managers or using built-in shell background processing
.. and that's what git-multi-hook is: a third-party hook manager, that uses shell background processing :)
- find-do-not-commit: do not commit files that include "DO NOT COMMIT"
- lint-code: run `$REPO/scripts/lint` if it exists
- lint-nodejs: run `$REPO/{pnpm/yarn/npm}` lint if `package.json` exists
- lint-shellcheck: shellcheck all the files that have no extensions or end in `.sh` that have a shell-shebang
- lint-swift: run swiftlint
- prevent-commit-secrets: run ripsecrets to avoid committing secrets and credentials
- validate: run `$REPO/scripts/validate` if it exists
By default all of the scripts check the files in the git staging area, but they can also be run standalone to check everything. You can find them here: https://github.com/webcoyote/git-multi-hook. Glad to take suggestions for more.
Git-multi-hook predates that, but I updated it to use the new 2.54 config-based format.
The significant advantage of git-multi-hook is that they all run in parallel. I run eight hooks on precommit, so parallelism is a big win.
I will update the README to make note. Thanks!