#!/usr/bin/env bash # # An example hook script to mail out commit update information. # Called by git-receive-pack with arguments: refname sha1-old sha1-new # # To enable this hook: # (1) change the recipient e-mail address # (2) make this file executable by "chmod +x update". # while read oldhead newhead ref; do refname=${ref#refs/heads/} [ "$refname" = "master" ] && refname= ### #for merged in $(git-rev-list $newhead ^$oldhead | tac); do ### # Do not repost merges: #### for merged in $(git-rev-list $newhead ^$oldhead $(for i in refs/heads/*; do echo ^$i; done) | tac) ; do for merged in $(git-rev-list $oldhead..$newhead | tac); do /srv/git/elinks.git/ciabot.pl -p elinks "$refname" $merged done done #chmod g+w /srv/git/elinks.git/$ref # 2>/dev/null exit 0