How to run local Git project hooks in addition to core.hooksPath global hooks?

git, githooks

Solution

I think the only way is for your global hooks to check if a corresponding local hook exists and run it.

This is not a complete solution because some hooks (`pre-push`, for example) accepts standard input in addition to command line parameters. If one of the hooks consumes the standard input the other doesn't have a chance.

Problem

Currently I'm using ``` git config --global core.hooksPath ~/.git/hooks ``` to configure global hooks for all my git projects. But if those projects contain hooks, they're not run. I'd like to run the global hook as well as the project hooks. Thank you!

Original source