TODO: GitHub -just
[girocco/radio.git] / post-receive-hook
blobc2c1251915d2fb9c28a14292a20172664f59d386
1 #!/bin/sh
3 # Send notification through the taskd socket
5 # Beware, we MAY be running in a chroot!
7 set -e
9 sockpath=/etc/taskd.socket
10 if [ -x /usr/bin/perl ]; then
11 # Not in chroot...
12 . @basedir@/shlib.sh
14 sockpath="$cfg_chroot/$sockpath"
17 [ -S "$sockpath" ] || exit 0
19 while read line; do
20 echo "ref-change $line"
21 done | /bin/nc.openbsd -w 1 -U "$sockpath"
23 exit