From f3b3ef9f0313658bb08836c3c1c4ec0c34013f6c Mon Sep 17 00:00:00 2001 From: Telesphoreo Date: Wed, 15 Mar 2023 16:06:31 -0500 Subject: [PATCH] Update Jenkinsfile --- Jenkinsfile | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 923e426..6af6046 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -30,12 +30,19 @@ pipeline { branch "1.18.2" } steps { - withCredentials([usernamePassword(credentialsId: '8150559b-ec1d-41bd-a576-aa668a52c1ba', passwordVariable: 'scissorsPassword', usernameVariable: 'scissorsUser')]) { - withGradle { - sh "./gradlew :Scissors-API:publish --no-daemon" - } - } - } + script { + try { + withCredentials([usernamePassword(credentialsId: 'scissors-ci', passwordVariable: 'scissorsPassword', usernameVariable: 'scissorsUser')]) { + withGradle { + sh "./gradlew :Scissors-API:publish --no-daemon" + } + } + true + } catch (_) { + false + } + } + } } } post { @@ -46,4 +53,4 @@ pipeline { cleanWs() } } -} \ No newline at end of file +}