Fix spurious error in triggers/upstream

The initial fetch of a new repo which has 'upstream' read-only mirroring
configured will cause a spurious error concerning FETCH_HEAD not yet
existing. This silences the error.
redis
Eugene E. Kashpureff Jr 2012-10-10 07:59:52 +00:00
parent 51ab768e2a
commit 896ada58c0
1 changed files with 1 additions and 1 deletions

View File

@ -11,7 +11,7 @@ cd $GL_REPO_BASE/$repo.git || exit 1
[ "$1" != "fetch" ] && {
nice=$(gitolite git-config $repo gitolite-options.upstream.nice)
[ -n "$nice" ] && find FETCH_HEAD -mmin -$nice | grep . >/dev/null && exit 0
[ -n "$nice" ] && find FETCH_HEAD -mmin -$nice 2>/dev/null | grep . >/dev/null && exit 0
}
git fetch -q "$url" '+refs/*:refs/*'