diff --git a/Jenkinsfile b/Jenkinsfile index 9535ebc2d6e92f77198a6dba813eb8d6164ec5cb..ac49afcb946db5f86097c662679b43a918d624f4 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -2,10 +2,19 @@ node{ stage('Git Checkout'){ checkout([$class: 'GitSCM', branches: [[name: '$Branches']], doGenerateSubmoduleConfigurations: false, extensions: [], gitTool: 'Default', submoduleCfg: [], userRemoteConfigs: [[credentialsId: 'a97e0ce1-814b-4e7d-832a-4ac3eed72506', url: 'git@gitlab.schbrain.com:zhangdongdong/test.git']]]) } - def pom = readMavenPom file: 'pom.xml' - echo "start echo pom" - echo "${pom}" - echo "end echo pom" + script{ + def pom = readMavenPom file: 'pom.xml' + echo "start echo pom" + echo "${pom}" + arr=(${pom}) + for s in ${arr[@]} + do + echo "$s" + done + + echo "end echo pom" + } + stage('Maven Build'){ sh "/var/jenkins_home/tools/apache-maven-3.6.3/bin/mvn clean -U package -Dversion=${version} -Dmaven.test.skip=true -P${profiles}" }