git2r
git2r copied to clipboard
Methods to list/add/remove hooks
Not strictly part of libgit2, but would be nice to have
Hooks are not supported by libgit2. However, there is an open PR to add initial support for hooks https://github.com/libgit2/libgit2/pull/3004
Before adding this functionality to git2r, wait and see which API functions libgit2 adds.
The PR referenced above (https://github.com/libgit2/libgit2/pull/3004) got closed with this conclusion: "libgit2 is not going to get hooks as such". So the stuff @hadley's suggesting will not be coming from libgit2.
I ended up here trying to confirm that git2r::commit()
does not honour pre-commit hooks. Indeed it does not and now I know why. For the same reason, clients like GitHub for Windows do not honour pre-commit hooks. ¯_(ツ)_/¯.