This repository is to track the various git hooks used by the CTPUG git infrastructure.
+We don't use the gitolite hooks via admin option, because it requires a less standard
+config.
+
These hooks are not automatically installed / deployed - that requires manual intervention
on the actual server.
This handles posting commit messages to Slack using the slack webhook interface
+### post-receive
+
+This is the global post-receive hook that dispatches messages to the appropriate
+notifiers if the config option is specified.
+
Scripts
------
### check-deploy
This can be run on the server to report any outdated hooks.
+
+check-deploy asumes that the hooks repo is checked out on the server to ~/local/gitolite-hooks
--- /dev/null
+#!/bin/bash
+
+cd ~/local/gitolite-hooks
+
+HOOK_DIR=~/.gitolite/hooks
+
+
+git pull
+
+for x in *; do
+ if [ "$x" = "check-deploy" ]; then
+ continue
+ elif [ "$x" = "README.md" ]; then
+ continue
+ fi
+ if [ ! -f $HOOK_DIR/$x ]; then
+ echo "$x doesn't exist in hook dir $HOOK_DIR"
+ continue
+ fi
+ if ! cmp $x $HOOK_DIR/$x; then
+ echo "$x differs from $HOOK_DIR/$x"
+ fi
+done