diff --git a/releng/promote-a-build.Jenkinsfile b/releng/promote-a-build.Jenkinsfile index ebc10af6d2f..e6cc8fa0111 100644 --- a/releng/promote-a-build.Jenkinsfile +++ b/releng/promote-a-build.Jenkinsfile @@ -3,8 +3,6 @@ pipeline { agent any parameters { booleanParam(defaultValue: true, description: 'Do a dry run of the build. All commands will be echoed.First run with this on, then when you are sure it is right, choose rebuild in the passing job and uncheck this box', name: 'DRY_RUN') - booleanParam(defaultValue: false, description: 'Include CDT standalone debugger when publishing (if applicable)', name: 'STANDALONE') - booleanParam(defaultValue: false, description: 'Publish only the standalon debugger. This is used to add the standalone debugger from a different job to the already published CDT release', name: 'STANDALONE_ONLY') string(defaultValue: '9.8', description: 'The major and minor version of CDT being released (e.g. 9.7, 9.8, 10.0).', name: 'MINOR_VERSION') string(defaultValue: 'cdt-9.8.0', description: 'The full name of this release (e.g. cdt-9.4.2, cdt-9.5.0-rc1, cdt-9.5.0-photon-m7, cdt-9.5.0-photon-rc1)', name: 'MILESTONE') string(defaultValue: 'cdt/job/main', description: 'The CI job name being promoted from (e.g. cdt/job/cdt_10_7, cdt/job/main', name: 'CDT_JOB_NAME') diff --git a/releng/scripts/promote-a-build.sh b/releng/scripts/promote-a-build.sh index f66ce380c5c..acea1368548 100755 --- a/releng/scripts/promote-a-build.sh +++ b/releng/scripts/promote-a-build.sh @@ -9,14 +9,11 @@ SSH="ssh ${SSHUSER}" SCP="scp" DOWNLOAD=/home/data/httpd/download.eclipse.org/tools/cdt/$RELEASE_OR_BUILD/$MINOR_VERSION/$MILESTONE ARTIFACTS=https://ci.eclipse.org/cdt/job/$CDT_JOB_NAME/$CDT_BUILD_NUMBER/artifact -INDEX_PHP_FOR_RCP=scripts/cdt-standalone-php-template.txt ARTIFACTS_REPO_TARGET=$ARTIFACTS/releng/org.eclipse.cdt.repo/target echo Using download location root of $DOWNLOAD echo Using artifacts location root of $ARTIFACTS - - echo Testing to make sure artifacts location is sane wget -q --output-document=/dev/null $ARTIFACTS @@ -27,48 +24,17 @@ else echo Dry run of build: fi +echo Testing to make sure we are publishing to a new directory +$SSH "test ! -e $DOWNLOAD" +$ECHO $SSH "mkdir -p $DOWNLOAD" -# The STANDALONE_ONLY flag is used to publish the standalone debugger from a -# different job (e.g. cdt-9.9-standalone-debugger job) after the main -# build has been published -if [ "$STANDALONE_ONLY" == "false" ]; then - echo Testing to make sure we are publishing to a new directory - $SSH "test ! -e $DOWNLOAD" - $ECHO $SSH "mkdir -p $DOWNLOAD" +$ECHO $SSH "cd $DOWNLOAD && \ + wget -q $ARTIFACTS_REPO_TARGET/repository/*zip*/repository.zip && \ + unzip -q repository.zip && \ + mv repository/* . && \ + rm -r repository repository.zip" - $ECHO $SSH "cd $DOWNLOAD && \ - wget -q $ARTIFACTS_REPO_TARGET/repository/*zip*/repository.zip && \ - unzip -q repository.zip && \ - mv repository/* . && \ - rm -r repository repository.zip" +$ECHO $SSH "cd $DOWNLOAD && \ + wget -q $ARTIFACTS_REPO_TARGET/org.eclipse.cdt.repo.zip && \ + mv org.eclipse.cdt.repo.zip $MILESTONE.zip" - $ECHO $SSH "cd $DOWNLOAD && \ - wget -q $ARTIFACTS_REPO_TARGET/org.eclipse.cdt.repo.zip && \ - mv org.eclipse.cdt.repo.zip $MILESTONE.zip" -fi - -# promote standalone debugger -if [ "$STANDALONE" == "true" ]; then - $ECHO $SSH "mkdir -p $DOWNLOAD/rcp" - - $ECHO $SSH "cd $DOWNLOAD/rcp && \ - wget -q $ARTIFACTS/debug/org.eclipse.cdt.debug.application.product/target/products/*zip*/products.zip && \ - unzip -q products.zip && \ - mv products/* ." - - if [ "$ECHO" == "echo" ]; then - # if there is a better way to handle echoing the pipeline, let me (Jonah) know - $ECHO Setting up index.php pipeline - else - cat $INDEX_PHP_FOR_RCP | sed "-es,CDT 9.4.0,$(echo $MILESTONE | sed '-es@cdt-@CDT @')," | $SSH "cat - > $DOWNLOAD/rcp/index.php" - fi - $ECHO $SSH "cd $DOWNLOAD/rcp && \ - rm -r products products.zip" - - $ECHO $SSH "mkdir $DOWNLOAD/rcp-repository" - $ECHO $SSH "cd $DOWNLOAD/rcp-repository && \ - wget -q $ARTIFACTS/debug/org.eclipse.cdt.debug.application.product/target/repository/*zip*/repository.zip && \ - unzip -q repository.zip && \ - mv repository/* . && \ - rm -r repository repository.zip" -fi