Improved setting error messages to jenkins job descriptions
Change-Id: Ia19224b7334d6fd468ecc40be87d5b4df795adc5
diff --git a/generate-cookiecutter-products.groovy b/generate-cookiecutter-products.groovy
index 9f96d61..1d8845d 100644
--- a/generate-cookiecutter-products.groovy
+++ b/generate-cookiecutter-products.groovy
@@ -184,7 +184,7 @@
} catch (Throwable e) {
// If there was an error or exception thrown, the build failed
currentBuild.result = "FAILURE"
- currentBuild.description = e.message
+ currentBuild.description = currentBuild.description ? e.message + " " + currentBuild.description : e.message
throw e
} finally {
stage ('Clean workspace directories') {