Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSravan Kumar Lakkimsetti2020-06-02 04:04:15 +0000
committerSravan Kumar Lakkimsetti2020-06-02 04:04:27 +0000
commit223782bafc59b111de4946fa3dbc1bc5d2b546fd (patch)
treec19b11de0ad331bd099c937e6de2033dffbba133 /cje-production
parent5bbf848eed1e7dc78375f3954558d01e153b4613 (diff)
downloadeclipse.platform.releng.aggregator-223782bafc59b111de4946fa3dbc1bc5d2b546fd.tar.gz
eclipse.platform.releng.aggregator-223782bafc59b111de4946fa3dbc1bc5d2b546fd.tar.xz
eclipse.platform.releng.aggregator-223782bafc59b111de4946fa3dbc1bc5d2b546fd.zip
Revert "Revert "Bug 563014 - Git log should be compare against last available build not just the tag""I20200602-0010
Diffstat (limited to 'cje-production')
-rwxr-xr-xcje-production/mbscripts/mb110_tagBuildInputs.sh21
1 files changed, 17 insertions, 4 deletions
diff --git a/cje-production/mbscripts/mb110_tagBuildInputs.sh b/cje-production/mbscripts/mb110_tagBuildInputs.sh
index 5d0000668..8f42b9631 100755
--- a/cje-production/mbscripts/mb110_tagBuildInputs.sh
+++ b/cje-production/mbscripts/mb110_tagBuildInputs.sh
@@ -1,7 +1,7 @@
#!/bin/bash
#*******************************************************************************
-# Copyright (c) 2019 IBM Corporation and others.
+# Copyright (c) 2019, 2020 IBM Corporation and others.
#
# This program and the accompanying materials
# are made available under the terms of the Eclipse Public License 2.0
@@ -27,8 +27,22 @@ reportTimestamp=$(TZ="America/New_York" date +%Y%m%d-%H%M --date='@'$reportDate)
gitLogFile=$CJE_ROOT/$DROP_DIR/$BUILD_ID/gitLog.html
mkdir -p $CJE_ROOT/$DROP_DIR/$BUILD_ID
-# set lastTag
-lastTag=$(git describe --tags --match "${BUILD_TYPE}*" --abbrev=0)
+epUpdateDir=/home/data/httpd/download.eclipse.org/eclipse/updates
+updateSiteRootPath=${epUpdateDir}/${STREAMMajor}.${STREAMMinor}-${BUILD_TYPE}-builds
+
+# try to find the last tag of the current build type that is available as a promoted build
+# by checking the most recent 5 tags and seeing if an update site for it exists
+lastTagList=$(git tag --list "${BUILD_TYPE}*" | tail -n5)
+lastTag=
+for lt in $lastTagList ; do
+ if ssh genie.releng@projects-storage.eclipse.org test -d ${updateSiteRootPath}/${lt} ; then
+ lastTag=$lt
+ fi
+done
+# if no build is promoted yet, then just fallback to the last tag of the current build type
+if [[ -z "$lastTag" ]] ; then
+ lastTag=$(git describe --tags --match "${BUILD_TYPE}*" --abbrev=0)
+fi
pushd $CJE_ROOT/$AGG_DIR
@@ -40,7 +54,6 @@ then
fi
git submodule foreach "if grep \"^\${name}:\" ../../../streams/repositories_$PATCH_OR_BRANCH_LABEL.txt > /dev/null; then git tag $BUILD_ID; git push --verbose origin $BUILD_ID; else echo Skipping \$name; fi || :"
-#git submodule foreach "if grep \"^\${name}:\" ../../../streams/repositories_$PATCH_OR_BRANCH_LABEL.txt > /dev/null; then git tag $BUILD_ID; else echo Skipping \$name; fi || :"
git tag $BUILD_ID
git push --verbose origin $BUILD_ID

Back to the top