Clean up directory where version meta is unpacked to before using.

master
Icedream 2018-05-07 20:49:32 +02:00
parent e36650d73d
commit 7a860b21c2
Signed by: icedream
GPG Key ID: 1573F6D8EFE4D0CF
1 changed files with 11 additions and 8 deletions

19
Jenkinsfile vendored
View File

@ -26,15 +26,18 @@ node("docker && linux && amd64") {
"--build-arg TOMCAT_VERSION=${tomcatVersion} --build-arg TOMCAT_JRE=${jreVersion} .") "--build-arg TOMCAT_VERSION=${tomcatVersion} --build-arg TOMCAT_JRE=${jreVersion} .")
def guacamoleVersion def guacamoleVersion
image.inside("-w /tmp") { image.inside() {
ansiColor { ansiColor {
sh """ dir("tmp") {
unzip /opt/guacamole/guacamole.war META-INF/maven/org.apache.guacamole/guacamole/pom.properties deleteDir()
""" sh """
guacamoleVersion = sh( unzip /opt/guacamole/guacamole.war META-INF/maven/org.apache.guacamole/guacamole/pom.properties
script: "grep -Po '(?i)^version=\\K.+\\s*\$' META-INF/maven/org.apache.guacamole/guacamole/pom.properties", """
returnStdout: true, guacamoleVersion = sh(
).trim() script: "grep -Po '(?i)^version=\\K.+\\s*\$' META-INF/maven/org.apache.guacamole/guacamole/pom.properties",
returnStdout: true,
).trim()
}
} }
} }
} }