Skip to content
Snippets Groups Projects
Commit 07a9bd1c authored by Martin's avatar Martin
Browse files

adjust getPomVersion function signature

parent 9b24c50f
No related branches found
No related tags found
No related merge requests found
......@@ -77,7 +77,7 @@ pipeline {
steps {
script {
FAILED_STAGE=env.STAGE_NAME
JAR_TAG = getPomVersion('pom.xml').replace("SNAPSHOT", "${env.BRANCH_NAME}-SNAPSHOT")
JAR_TAG = getPomVersion().replace("SNAPSHOT", "${env.BRANCH_NAME}-SNAPSHOT")
}
configFileProvider([configFile(fileId: 'maven-settings', variable: 'MAVEN_SETTINGS')]) {
sh "mvn -s $MAVEN_SETTINGS versions:set -DnewVersion=${JAR_TAG} -DprocessAllModules=true"
......@@ -250,7 +250,7 @@ String getHelmRepoUrl(){
}
String generateHelmChartVersion() {
def chartVersion = getPomVersion('pom.xml')
def chartVersion = getPomVersion()
if (isMainBranch()) {
chartVersion += "-${env.GIT_COMMIT.take(7)}"
......@@ -366,8 +366,8 @@ Void tagAndPushDockerImage(String imageName, String newTag){
}
}
String getPomVersion(String pomFile){
def pom = readMavenPom file: pomFile
String getPomVersion(){
def pom = readMavenPom file: 'pom.xml'
return pom.version
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment