1
0
mirror of https://github.com/SAP/jenkins-library.git synced 2025-01-18 05:18:24 +02:00

Fix version determination 2

This commit is contained in:
Sven Merk 2019-03-25 08:41:30 +01:00
parent c269746ed3
commit 50cc1cb32d

View File

@ -416,7 +416,8 @@ private resolveProjectIdentifiers(script, descriptorUtils, config) {
if(!config.whitesource.projectName)
config.whitesource.projectName = "${gav.group?:''}${gav.group?'.':''}${gav.artifact}"
def version = gav.version?.tokenize('.')?.head()
def versionFragments = gav.version?.tokenize('.')
def version = versionFragments ? versionFragments.head() : null
if(version && !config.whitesource.productVersion)
config.whitesource.productVersion = version
}