From f45900b3272030a758a6f6c347024e6760ae4ed5 Mon Sep 17 00:00:00 2001 From: Thierry Parmentelat Date: Mon, 24 May 2010 21:01:45 +0200 Subject: [PATCH] need to retrieve BUILD_SCM_URL before updating the build itself, only then can we pick svn or git --- vbuild-nightly.sh | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/vbuild-nightly.sh b/vbuild-nightly.sh index fe966d37..38a2c01d 100755 --- a/vbuild-nightly.sh +++ b/vbuild-nightly.sh @@ -560,6 +560,15 @@ function main () { echo "XXXXXXXXXX $COMMAND: using existing vserver $BASE" $(date) # start in case e.g. we just rebooted vserver ${BASE} start || : + # retrieve environment from the previous run + FCDISTRO=$(vserver ${BASE} exec /build/getdistroname.sh) + BUILD_SCM_URL=$(vserver ${BASE} exec make --no-print-directory -C /build stage1=skip +build-SVNPATH +build-GITPATH) + # for efficiency, crop everything in one make run + tmp=/tmp/${BASE}-env.sh + vserver ${BASE} exec make --no-print-directory -C /build stage1=skip \ + ++PLDISTRO ++PLDISTROTAGS ++PERSONALITY ++MAILTO ++WEBPATH ++TESTBUILDURL ++WEBROOT > $tmp + . $tmp + rm -f $tmp # update build [ -n "$SSH_KEY" ] && setupssh ${BASE} ${SSH_KEY} if echo $BUILD_SCM_URL | grep -q git ; then @@ -569,16 +578,6 @@ function main () { fi # make sure we refresh the tests place in case it has changed rm -f /build/MODULES/tests - # get environment from the first run - FCDISTRO=$(vserver ${BASE} exec /build/getdistroname.sh) - # retrieve all in one run - tmp=/tmp/${BASE}-env.sh - vserver ${BASE} exec make --no-print-directory -C /build stage1=skip \ - ++PLDISTRO ++PLDISTROTAGS ++PERSONALITY ++MAILTO ++WEBPATH ++TESTBUILDURL ++WEBROOT > $tmp - # sh vars cannot have a minus - echo BUILD_SCM_URL=$(vserver ${BASE} exec make --no-print-directory -C /build stage1=skip +build-SVNPATH +build-GITPATH) >> $tmp - . $tmp - rm -f $tmp options=(${options[@]} -d $PLDISTRO -t $PLDISTROTAGS -s $BUILD_SCM_URL) [ -n "$PERSONALITY" ] && options=(${options[@]} -p $PERSONALITY) [ -n "$MAILTO" ] && options=(${options[@]} -m $MAILTO) -- 2.47.0