Skip to content
Snippets Groups Projects
Commit 147839e2 authored by Andreas Dilger's avatar Andreas Dilger Committed by Oleg Drokin
Browse files

LU-2083 build: install git commit hooks automatically


Install the Lustre Git commit hooks into .git/hooks/ by default when
autogen.sh is run, so that they are present when patches are being
committed.  This avoids the relatively common case where a new tree
is checked out by new or experienced developers and is missing the
commit hooks when patches are being submitted.

While the commit hooks are sure to be installed for in any tree that
was built, this isn't a guarantee that the hooks will be installed in
every tree that has a commit, but it is very likely to be the case.

Signed-off-by: default avatarAndreas Dilger <adilger@whamcloud.com>
Change-Id: I6a15420fb7a35b790c1e816c67e20a8004500c1e
Reviewed-on: http://review.whamcloud.com/4175


Tested-by: Hudson
Tested-by: default avatarMaloo <whamcloud.maloo@gmail.com>
Reviewed-by: default avatarYu Jian <yujian@whamcloud.com>
Reviewed-by: default avatarWei Liu <wei3.liu@intel.com>
Reviewed-by: default avatarBruce Korb <bruce_korb@xyratex.com>
Reviewed-by: default avatarOleg Drokin <green@whamcloud.com>
parent 75ad0b75
No related branches found
No related tags found
No related merge requests found
#!/bin/sh
# install Lustre Git commit hooks by default - LU-2083
for HOOK in commit-msg prepare-commit-msg; do
[ -e .git/hooks/$HOOK ] || ln -sf ../build/$HOOK .git/hooks/
done
exec bash build/autogen.sh $@
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment