@matheusbsbs / matheus-bagliano / commits / a204756a45
Fork 0

sample hooks template.

These two sample hooks try to detect and use the corresponding commit hook from the same repository. However, they forgot to set up GIT_DIR for their own use, so was not in effect. Signed-off-by: Junio C Hamano <junkio@cox.net>

Junio C Hamano committed Feb 26, 2006 at 15:16 UTC a204756a45bd357280c156d01858138712493dfa
2 files changed +2
templates/hooks--applypatch-msg
+1
@@ -9,6 +9,7 @@
9 #
10 # To enable this hook, make this file executable.
11
12 +. git-sh-setup
13 test -x "$GIT_DIR/hooks/commit-msg" &&
14 exec "$GIT_DIR/hooks/commit-msg" ${1+"$@"}
15 :
templates/hooks--pre-applypatch
+1
@@ -8,6 +8,7 @@
8 #
9 # To enable this hook, make this file executable.
10
11 +. git-sh-setup
12 test -x "$GIT_DIR/hooks/pre-commit" &&
13 exec "$GIT_DIR/hooks/pre-commit" ${1+"$@"}
14 :