From 9141cb4866f6c0c1f85f913ae38a49f5abdd43df Mon Sep 17 00:00:00 2001 From: CaptainB Date: Thu, 17 Mar 2022 19:40:17 +0800 Subject: [PATCH] =?UTF-8?q?build:=20=E4=BD=BF=E7=94=A8jdk11=E8=BF=90?= =?UTF-8?q?=E8=A1=8C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Jenkinsfile | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index c6d19446e6..5bbb30e141 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -13,10 +13,14 @@ pipeline { stage('Build/Test') { steps { configFileProvider([configFile(fileId: 'metersphere-maven', targetLocation: 'settings.xml')]) { - sh 'export JAVA_HOME=/opt/jdk-11;export CLASSPATH=$JAVA_HOME/lib:$CLASSPATH;export PATH=$JAVA_HOME/bin:$PATH' - sh 'java -version' - sh "./mvnw clean package --settings ./settings.xml" - sh "mkdir -p backend/target/dependency && (cd backend/target/dependency; jar -xf ../*.jar)" + sh ''' + export JAVA_HOME=/opt/jdk-11 + export CLASSPATH=$JAVA_HOME/lib:$CLASSPATH + export PATH=$JAVA_HOME/bin:$PATH + java -version + ./mvnw clean package --settings ./settings.xml + mkdir -p backend/target/dependency && (cd backend/target/dependency; jar -xf ../*.jar) + ''' } } }