diff --git a/Jenkinsfile b/Jenkinsfile index 4b29899..f2fab41 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -87,7 +87,7 @@ foreach ($target in $targets) { break } } catch { - Write-Host "Taiga lookup warning: $($_.Exception.Message)" + Write-Host "Taiga lookup warning" } } @@ -108,14 +108,17 @@ try { Invoke-RestMethod -Uri $url -Headers $headers -Method Patch -Body $body Write-Host "Commented Taiga TG-$ref ($($found.label))" } catch { - Write-Host "Taiga comment warning: $($_.Exception.Message)" + Write-Host "Taiga comment warning" } exit 0 ''' withEnv(["BUILD_RESULT=${result}"]) { - powershell(returnStatus: true, file: 'taiga-post.ps1') + bat(returnStatus: true, script: ''' + powershell -NoProfile -ExecutionPolicy Bypass -File taiga-post.ps1 + exit /b 0 + ''') } } }