generated from gCubeCI/Pipeline-Docker-Template
fixing parsing function
This commit is contained in:
parent
05a40c0546
commit
a3d11b44c5
|
@ -145,12 +145,12 @@ pipeline {
|
||||||
|
|
||||||
//a non CPS method is necessary for the usage of splitEachLine()
|
//a non CPS method is necessary for the usage of splitEachLine()
|
||||||
@NonCPS
|
@NonCPS
|
||||||
def parseDeployComponentNex(def deployList) {
|
def parseDeployComponent(def deployList) {
|
||||||
println "Going to parsing file ${deployList}"
|
println "Going to parsing file ${deployList}"
|
||||||
def components = []
|
def components = []
|
||||||
"${deployList}".splitEachLine(',') { columns ->
|
"${deployList}".splitEachLine(',') { columns ->
|
||||||
if (columns[0].startsWith('#') || columns[0].startsWith('Component'))
|
// if (columns[0].startsWith('#') || columns[0].startsWith('Component'))
|
||||||
return
|
// return
|
||||||
components.add([
|
components.add([
|
||||||
name : columns[1],
|
name : columns[1],
|
||||||
version : columns[2]
|
version : columns[2]
|
||||||
|
@ -159,21 +159,3 @@ def parseDeployComponentNex(def deployList) {
|
||||||
}
|
}
|
||||||
return components
|
return components
|
||||||
}
|
}
|
||||||
|
|
||||||
//a non CPS method is necessary for the usage of splitEachLine()
|
|
||||||
@NonCPS
|
|
||||||
def parseDeployComponent(def deployList) {
|
|
||||||
def components = []
|
|
||||||
"${deployList}".splitEachLine(',') { columns ->
|
|
||||||
if (columns[0].startsWith('#') || columns[0].startsWith('GroupID'))
|
|
||||||
return
|
|
||||||
components.add([
|
|
||||||
name : columns[1],
|
|
||||||
version : columns[2],
|
|
||||||
gitRepo : columns[3],
|
|
||||||
commitID: columns[4]
|
|
||||||
]
|
|
||||||
)
|
|
||||||
}
|
|
||||||
return components
|
|
||||||
}
|
|
Loading…
Reference in New Issue