Jenkins Test #14

This commit is contained in:
2025-10-08 18:17:33 +02:00
parent 4922305921
commit fc9a4bdc47

11
Jenkinsfile vendored
View File

@@ -89,15 +89,17 @@ pipeline {
post { post {
success { success {
script { script {
// Construit une liste de chaînes JSON manuellement // Prépare la liste d'URL brutes
def urlsList = [] def urlsList = []
if (params.BUILD_TYPE in ['Both','Debug']) { if (params.BUILD_TYPE in ['Both','Debug']) {
urlsList << "\"${env.BUILD_URL}artifact/builds/KhaoticEngineReborn_Debug.zip\"" urlsList << "${env.BUILD_URL}artifact/builds/KhaoticEngineReborn_Debug.zip"
} }
if (params.BUILD_TYPE in ['Both','Release']) { if (params.BUILD_TYPE in ['Both','Release']) {
urlsList << "\"${env.BUILD_URL}artifact/builds/KhaoticEngineReborn_Release.zip\"" urlsList << "${env.BUILD_URL}artifact/builds/KhaoticEngineReborn_Release.zip"
} }
def urlsJson = "[${urlsList.join(',')}]" // Fabrication manuelle d'un JSON array de strings
def urlsJson = urlsList.collect { "\"${it}\"" }.join(',' )
urlsJson = "[${urlsJson}]"
bat """ bat """
curl -X POST http://192.168.1.131:2500/ci-notify ^ curl -X POST http://192.168.1.131:2500/ci-notify ^
@@ -116,5 +118,4 @@ pipeline {
} }
} }
} }
} }