Skip to content

Commit

Permalink
Fix hooks to work with older branches
Browse files Browse the repository at this point in the history
  • Loading branch information
philwhineray committed Jan 10, 2016
1 parent 2f0460b commit 8b472fd
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 1 deletion.
2 changes: 2 additions & 0 deletions hooks/post-commit
Expand Up @@ -2,4 +2,6 @@
if [ -x ./packaging/update-tags ]
then
exec git diff HEAD^ | ./packaging/update-tags -
else
exit 0
fi
2 changes: 2 additions & 0 deletions hooks/pre-commit
Expand Up @@ -2,4 +2,6 @@
if [ -x ./packaging/check-files ]
then
exec git diff --cached | ./packaging/check-files -
else
exit 0
fi
7 changes: 6 additions & 1 deletion hooks/prepare-commit-msg
@@ -1,2 +1,7 @@
#!/bin/sh
test -x ./packaging/release-msg && exec ./packaging/release-msg "$@"
if [ -x ./packaging/release-msg ]
then
exec ./packaging/release-msg "$@"
else
exit 0
fi

0 comments on commit 8b472fd

Please sign in to comment.