chiark / gitweb /
autogen.sh: enable git pre-commit
authorKay Sievers <kay.sievers@vrfy.org>
Thu, 5 Jan 2012 18:22:03 +0000 (19:22 +0100)
committerKay Sievers <kay.sievers@vrfy.org>
Thu, 5 Jan 2012 18:22:03 +0000 (19:22 +0100)
autogen.sh

index fdbff66..582a8a3 100755 (executable)
@@ -2,6 +2,12 @@
 
 set -e
 
+if [ -f .git/hooks/pre-commit.sample -a ! -f .git/hooks/pre-commit ] ; then
+    cp -p .git/hooks/pre-commit.sample .git/hooks/pre-commit && \
+    chmod +x .git/hooks/pre-commit && \
+    echo "Activated pre-commit hook."
+fi
+
 gtkdocize
 autoreconf --install --symlink