Skip to content

Commit

Permalink
no longer need che-lib - eclipse-che/che#14592
Browse files Browse the repository at this point in the history
Change-Id: Id37c241812bbfbcc72b8bdcb1677d7f39b8e4cea
Signed-off-by: nickboldt <[email protected]>
  • Loading branch information
nickboldt committed Oct 9, 2019
1 parent 472cedb commit 4015489
Showing 1 changed file with 26 additions and 29 deletions.
55 changes: 26 additions & 29 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
// nodeBig == slave label, eg., rhel7-devstudio-releng-16gb-ram||rhel7-16gb-ram or rhel7-32gb||rhel7-16gb
// branchToBuildDev = refs/tags/20
// branchToBuildParent = refs/tags/7.0.0-RC-2.0
// branchToBuildLib = refs/tags/7.0.0-RC-2.0
// branchToBuildChe = refs/tags/7.0.0-RC-2.0 or */*/7.0.0-RC-2.x or */master
// branchToBuildLSJ = refs/tags/0.0.3 or */master or a SHA like 095d753f42dad32c47b1e9ae46a71bf424e98e7e
// branchToBuildCRW = */7.0.0-RC-2.x or */master
Expand Down Expand Up @@ -77,30 +76,31 @@ timeout(120) {
}
}

def LIB_path = "che-lib"
def VER_LIB = "VER_LIB"
def SHA_LIB = "SHA_LIB"
timeout(120) {
node("${node}"){ stage "Build ${LIB_path}"
cleanWs()
checkout([$class: 'GitSCM',
branches: [[name: "${branchToBuildLib}"]],
doGenerateSubmoduleConfigurations: false,
poll: true,
extensions: [[$class: 'RelativeTargetDirectory', relativeTargetDir: "${LIB_path}"]],
submoduleCfg: [],
userRemoteConfigs: [[url: "https://github.com/eclipse/${LIB_path}.git"]]])
unstash 'stashParent'
installNPM()
buildMaven()
sh "mvn clean install ${MVN_FLAGS} -f ${LIB_path}/pom.xml ${MVN_EXTRA_FLAGS}"
stash name: 'stashLib', includes: findFiles(glob: '.repository/**').join(", ")

sh "perl -0777 -p -i -e 's|(\\ +<parent>.*?<\\/parent>)| ${1} =~ /<version>/?\"\":${1}|gse' ${LIB_path}/pom.xml"
VER_LIB = sh(returnStdout:true,script:"egrep \"<version>\" ${LIB_path}/pom.xml|head -1|sed -e \"s#.*<version>\\(.\\+\\)</version>#\\1#\"").trim()
SHA_LIB = sh(returnStdout:true,script:"cd ${LIB_path}/ && git rev-parse --short=4 HEAD").trim()
}
}
// // no longer require https://github.com/eclipse/che/pull/14592
// def LIB_path = "che-lib"
// def VER_LIB = "VER_LIB"
// def SHA_LIB = "SHA_LIB"
// timeout(120) {
// node("${node}"){ stage "Build ${LIB_path}"
// cleanWs()
// checkout([$class: 'GitSCM',
// branches: [[name: "${branchToBuildLib}"]],
// doGenerateSubmoduleConfigurations: false,
// poll: true,
// extensions: [[$class: 'RelativeTargetDirectory', relativeTargetDir: "${LIB_path}"]],
// submoduleCfg: [],
// userRemoteConfigs: [[url: "https://github.com/eclipse/${LIB_path}.git"]]])
// unstash 'stashParent'
// installNPM()
// buildMaven()
// sh "mvn clean install ${MVN_FLAGS} -f ${LIB_path}/pom.xml ${MVN_EXTRA_FLAGS}"
// stash name: 'stashLib', includes: findFiles(glob: '.repository/**').join(", ")

// sh "perl -0777 -p -i -e 's|(\\ +<parent>.*?<\\/parent>)| ${1} =~ /<version>/?\"\":${1}|gse' ${LIB_path}/pom.xml"
// VER_LIB = sh(returnStdout:true,script:"egrep \"<version>\" ${LIB_path}/pom.xml|head -1|sed -e \"s#.*<version>\\(.\\+\\)</version>#\\1#\"").trim()
// SHA_LIB = sh(returnStdout:true,script:"cd ${LIB_path}/ && git rev-parse --short=4 HEAD").trim()
// }
// }

def LSJ_path = "che-ls-jdt"
def VER_LSJ = "VER_LSJ"
Expand All @@ -115,7 +115,7 @@ timeout(120) {
extensions: [[$class: 'RelativeTargetDirectory', relativeTargetDir: "${LSJ_path}"]],
submoduleCfg: [],
userRemoteConfigs: [[url: "https://github.com/eclipse/${LSJ_path}.git"]]])
unstash 'stashLib'
unstash 'stashParent'
installNPM()
installGo()
buildMaven()
Expand Down Expand Up @@ -195,7 +195,6 @@ timeout(180) {
CRW_SHAs="${VER_CRW} :: ${BUILDINFO} \
:: ${DEV_path} @ ${SHA_DEV} (${VER_DEV}) \
:: ${PAR_path} @ ${SHA_PAR} (${VER_PAR}) \
:: ${LIB_path} @ ${SHA_LIB} (${VER_LIB}) \
:: ${LSJ_path} @ ${SHA_LSJ} (${VER_LSJ}) \
:: ${CHE_path} @ ${SHA_CHE} (${VER_CHE}) \
:: ${CRW_path} @ ${SHA_CRW} (${VER_CRW})"
Expand Down Expand Up @@ -247,7 +246,6 @@ timeout(120) {
CRW_SHAs="${VER_CRW} :: ${BUILDINFO} \
:: ${DEV_path} @ ${SHA_DEV} (${VER_DEV}) \
:: ${PAR_path} @ ${SHA_PAR} (${VER_PAR}) \
:: ${LIB_path} @ ${SHA_LIB} (${VER_LIB}) \
:: ${LSJ_path} @ ${SHA_LSJ} (${VER_LSJ}) \
:: ${CHE_path} @ ${SHA_CHE} (${VER_CHE}) \
:: ${CRW_path} @ ${SHA_CRW} (${VER_CRW})"
Expand All @@ -271,7 +269,6 @@ timeout(120) {
+ "Build #${BUILD_NUMBER} (${BUILD_TIMESTAMP}) <br/>\
:: ${DEV_path} @ ${SHA_DEV} (${VER_DEV}) <br/>\
:: ${PAR_path} @ ${SHA_PAR} (${VER_PAR}) <br/>\
:: ${LIB_path} @ ${SHA_LIB} (${VER_LIB}) <br/>\
:: ${LSJ_path} @ ${SHA_LSJ} (${VER_LSJ}) <br/>\
:: ${CHE_path} @ ${SHA_CHE} (${VER_CHE}) <br/>\
:: ${CRW_path} @ ${SHA_CRW} (${VER_CRW})"
Expand Down

0 comments on commit 4015489

Please sign in to comment.