fix again json syntax

This commit is contained in:
Roberto Cirillo 2023-06-15 16:07:00 +02:00
parent 1a63a95de4
commit 1609eb2c1e
1 changed files with 1 additions and 1 deletions

2
Jenkinsfile vendored
View File

@ -368,7 +368,7 @@ def deployRelease(def categoryList, def yaml){
}else if (category =="${PORTLET_CATEGORY}"){ }else if (category =="${PORTLET_CATEGORY}"){
//def portlets="{\"generic_portlets\": "; //def portlets="{\"generic_portlets\": ";
// portlets += component_list?.collect{ return [ 'name': "$it.name", 'version': "$it.version", 'extension': 'war' ] } // portlets += component_list?.collect{ return [ 'name': "$it.name", 'version': "$it.version", 'extension': 'war' ] }
portlets += component_list?.collect{ return " name: $it.name, version: $it.version, extension: war " } portlets += component_list?.collect{ return " \"name\": \"$it.name\", \"version\": \"$it.version\", \"extension\": \"war\" "}
echo "portlets: $portlets" echo "portlets: $portlets"
def jsonContent= "{\"generic_portlets\":"+portlets+"}" def jsonContent= "{\"generic_portlets\":"+portlets+"}"
echo "json: $jsonContent" echo "json: $jsonContent"