Fix fetch of STAGE_REPO_ID 89/78489/1
authorThanh Ha <thanh.ha@linuxfoundation.org>
Thu, 6 Dec 2018 01:00:13 +0000 (09:00 +0800)
committerThanh Ha <thanh.ha@linuxfoundation.org>
Thu, 6 Dec 2018 01:02:28 +0000 (09:02 +0800)
The patch Ib9066f85ff135bbba88410e8e2efb5345311c414 broke the post
build scripts from properly getting the staging repo ID.
The lf-maven-stage macro produces a parsed file staging-repo.txt
which contains the repo already and we no longer need to parse the
full Maven log to find this detail.

Change-Id: Id5ce6b416f6e2002bf5b204ca3f1843f6c76d51c
Signed-off-by: Thanh Ha <thanh.ha@linuxfoundation.org>
jjb/autorelease/autorelease-get-integration-test-variables.sh

index e7e347f47d00b9c4dce52f7e52557f9e6f8d1591..ad4a7015d5dc5999541ac543a79778338b6a7326 100644 (file)
@@ -19,7 +19,7 @@ NEXUS_STAGING_URL="${ODLNEXUS_STAGING_URL:-$ODLNEXUSPROXY}"
 NEXUSURL="${NEXUS_STAGING_URL}/content/repositories/"
 VERSION=$(grep -m2 '<version>' "${WORKSPACE}/integration/distribution/${KARAF_ARTIFACT}/pom.xml" | tail -n1 | awk -F'[<|>]' '/version/ { printf $3 }')
 echo "VERSION: ${VERSION}"
-STAGING_REPO_ID=$(grep "Created staging repository with ID" "$WORKSPACE/deploy-staged-repository.log" | cut -d '"' -f2)
+STAGING_REPO_ID=$(grep "$NEXUS_STAGING_URL" "$WORKSPACE/archives/staging-repo.txt" | awk '{print $1}')
 BUNDLE_URL="${NEXUSURL}/${STAGING_REPO_ID}/org/opendaylight/integration/${KARAF_ARTIFACT}/${VERSION}/${KARAF_ARTIFACT}-${VERSION}.zip"
 echo STAGING_REPO_ID="$STAGING_REPO_ID" >> "$WORKSPACE/variables.prop"
 echo BUNDLE_URL="$BUNDLE_URL" >> "$WORKSPACE/variables.prop"