mirror of
https://github.com/eclipse-cdt/cdt
synced 2024-10-28 03:59:40 +01:00
Add cdt-lsp support to the promote-a-build scripts
Part of https://github.com/eclipse-cdt/cdt-lsp/issues/197
This commit is contained in:
parent
4588c7694b
commit
69bd1cb4cf
2 changed files with 17 additions and 7 deletions
|
@ -3,9 +3,10 @@ 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')
|
||||
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')
|
||||
string(defaultValue: '9.8', description: 'The major and minor version of CDT being released (e.g. 11.3, 12.0, cdt-lsp-1.0, cdt-lsp-1.1).', 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-lsp-1.0.0, cdt-lsp-1.0.0-rc1)', name: 'MILESTONE')
|
||||
choice(choices: ['cdt', 'cdt-lsp'], description: 'The repo being published', name: 'CDT_REPO')
|
||||
string(defaultValue: 'main', description: 'The repo branch being published (e.g. main, master, cdt_11_3)', name: 'CDT_BRANCH')
|
||||
string(defaultValue: '12345', description: 'The CI build number being promoted from', name: 'CDT_BUILD_NUMBER')
|
||||
choice(choices: ['releases', 'builds'], description: 'Publish location (releases or builds)', name: 'RELEASE_OR_BUILD')
|
||||
}
|
||||
|
|
|
@ -8,8 +8,17 @@ SSHUSER="genie.cdt@projects-storage.eclipse.org"
|
|||
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
|
||||
ARTIFACTS_REPO_TARGET=$ARTIFACTS/releng/org.eclipse.cdt.repo/target
|
||||
ARTIFACTS=https://ci.eclipse.org/cdt/job/$CDT_REPO/job/$CDT_BRANCH/$CDT_BUILD_NUMBER/artifact
|
||||
if [ "$CDT_REPO" == "cdt" ]; then
|
||||
ARTIFACTS_REPO_TARGET=$ARTIFACTS/releng/org.eclipse.cdt.repo/target
|
||||
ZIP_NAME=org.eclipse.cdt.repo.zip
|
||||
elif [ "$CDT_REPO" == "cdt-lsp" ]; then
|
||||
ARTIFACTS_REPO_TARGET=$ARTIFACTS/releng/org.eclipse.cdt.lsp.repository/target
|
||||
ZIP_NAME=org.eclipse.cdt.lsp.repository.zip
|
||||
else
|
||||
echo "unexpected value for CDT_REPO: ${CDT_REPO}"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo Using download location root of $DOWNLOAD
|
||||
echo Using artifacts location root of $ARTIFACTS
|
||||
|
@ -35,6 +44,6 @@ $ECHO $SSH "cd $DOWNLOAD && \
|
|||
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"
|
||||
wget -q $ARTIFACTS_REPO_TARGET/$ZIP_NAME && \
|
||||
mv $ZIP_NAME $MILESTONE.zip"
|
||||
|
||||
|
|
Loading…
Reference in a new issue