From f1492c324f3be50c6a7b3d421b7f040ac8d1c8fe Mon Sep 17 00:00:00 2001 From: garciadeblas Date: Wed, 16 Dec 2020 16:05:34 +0000 Subject: [PATCH] ci_stage_1.groovy: clean-up indentation Change-Id: I0745dc2e4dfd94b17b2403542e2aae3023530bb8 Signed-off-by: garciadeblas --- jenkins/ci-pipelines/ci_stage_1.groovy | 46 ++++++++++++-------------- 1 file changed, 22 insertions(+), 24 deletions(-) diff --git a/jenkins/ci-pipelines/ci_stage_1.groovy b/jenkins/ci-pipelines/ci_stage_1.groovy index 53466f75..0f530c52 100644 --- a/jenkins/ci-pipelines/ci_stage_1.groovy +++ b/jenkins/ci-pipelines/ci_stage_1.groovy @@ -96,7 +96,7 @@ node("${params.NODE}") { println("TEST_INSTALL = ${params.TEST_INSTALL}, downstream job: ${downstream_job_name}") currentBuild.result = 'SUCCESS' try { - stage_3_merge_result = build job: "${downstream_job_name}", parameters: downstream_params, propagate: true + stage_3_merge_result = build job: "${downstream_job_name}", parameters: downstream_params, propagate: true if (stage_3_merge_result.getResult() != 'SUCCESS') { project = stage_3_merge_result.getProjectName() build = stage_3_merge_result.getNumber() @@ -104,28 +104,26 @@ node("${params.NODE}") { // error("${project} build ${build} failed") currentBuild.result = stage_3_merge_result.getResult() } - } - catch(caughtError) { - echo 'Exception in stage_1' - currentBuild.result = 'FAILURE' - } - finally { - try { - if((currentBuild.result != 'SUCCESS') && (env.JOB_NAME == 'daily-stage_4')){ - emailext ( - subject: "[OSM-Jenkins] Job: ${env.JOB_NAME} Build: ${env.BUILD_NUMBER} Result: ${currentBuild.result}", - body: """ Check console output at "${env.BUILD_URL}" """, - to: 'OSM_MDL@list.etsi.org', - recipientProviders: [culprits()] - ) + } + catch(caughtError) { + echo 'Exception in stage_1' + currentBuild.result = 'FAILURE' + } + finally { + try { + if((currentBuild.result != 'SUCCESS') && (env.JOB_NAME == 'daily-stage_4')){ + emailext ( + subject: "[OSM-Jenkins] Job: ${env.JOB_NAME} Build: ${env.BUILD_NUMBER} Result: ${currentBuild.result}", + body: """ Check console output at "${env.BUILD_URL}" """, + to: 'OSM_MDL@list.etsi.org', + recipientProviders: [culprits()] + ) + } } - } - catch(caughtError) { - echo "Failure in executing email" - } - - } - } + catch(caughtError) { + echo "Failure in executing email" + } + } + } +} - - } -- 2.25.1