2009-10-02 23:23:52 +05:30
|
|
|
#!/bin/sh
|
|
|
|
|
2009-10-03 13:17:02 +05:30
|
|
|
# checkout the master branch to $GL_ADMINDIR
|
2009-12-15 12:35:48 +05:30
|
|
|
# (the GL_ADMINDIR env var would have been set by gl-auth-command)
|
2010-04-12 20:50:26 +05:30
|
|
|
GIT_WORK_TREE=$GL_ADMINDIR git checkout -f master -- \
|
2010-04-12 23:46:29 +05:30
|
|
|
`git ls-tree --name-only master | perl -lne 'print unless /^(src|hooks)$/'`
|
2009-10-03 13:17:02 +05:30
|
|
|
|
2010-03-30 17:53:40 +05:30
|
|
|
od=$PWD
|
2009-10-03 13:17:02 +05:30
|
|
|
cd $GL_ADMINDIR
|
2009-12-15 12:35:48 +05:30
|
|
|
$GL_BINDIR/gl-compile-conf
|
2010-03-16 19:26:26 +05:30
|
|
|
|
2010-03-30 17:53:40 +05:30
|
|
|
cd $od
|
2010-03-17 20:36:51 +05:30
|
|
|
|
2010-04-13 18:26:34 +05:30
|
|
|
ADMIN_POST_UPDATE_CHAINS_TO=` cd;perl -e 'do ".gitolite.rc"; print $ADMIN_POST_UPDATE_CHAINS_TO'`
|
|
|
|
[ -n "$ADMIN_POST_UPDATE_CHAINS_TO" ] || ADMIN_POST_UPDATE_CHAINS_TO=hooks/post-update.secondary
|
|
|
|
|
|
|
|
if [ -f $ADMIN_POST_UPDATE_CHAINS_TO ] || [ -L $ADMIN_POST_UPDATE_CHAINS_TO ]
|
2010-03-16 19:26:26 +05:30
|
|
|
then
|
2010-04-13 18:26:34 +05:30
|
|
|
exec $ADMIN_POST_UPDATE_CHAINS_TO "$@"
|
2010-03-16 19:26:26 +05:30
|
|
|
fi
|