@@ -46,7 +46,6 @@ def syncJckMaterial(){
46
46
def JCK_GIT_BRANCH = params. JCK_GIT_BRANCH ? " -gb ${ params.JCK_GIT_BRANCH} " : " "
47
47
def ARTIFACTORY_URL = params. ARTIFACTORY_URL ? " -au ${ params.ARTIFACTORY_URL} " : " "
48
48
def JCK_GIT_REPO = params. JCK_GIT_REPO ? " -repo ${ params.JCK_GIT_REPO} " : " "
49
- def EXITCODE = 1
50
49
stage(' JCKUpdater' ) {
51
50
getJavaSDK()
52
51
@@ -60,12 +59,12 @@ def syncJckMaterial(){
60
59
sshagent(credentials :[" ${ params.USER_CREDENTIALS_ID} " ], ignoreMissing : true ){
61
60
def SCRIPT = " ./jckupdater.sh ${ JCK_VERSION} -at \"\$ ARTIFACTORY_CREDENTIALS\" ${ JCK_GIT_REPO} -gt \"\$ GIT_CREDENTIALS\" ${ ARTIFACTORY_URL} ${ JCK_GIT_BRANCH} "
62
61
def tempOutputFile = " temp_output.txt"
63
- EXITCODE = sh(script : " ${ SCRIPT} > ${ tempOutputFile} " , returnStatus : true )
62
+ def EXITCODE = sh(script : " ${ SCRIPT} > ${ tempOutputFile} " , returnStatus : true )
64
63
def scriptOutput = readFile(tempOutputFile). trim()
65
- echo (" jckupdater script output:" )
64
+ echo (" JCKUpdater script output:" )
66
65
echo scriptOutput
67
66
if (EXITCODE == 2 ) {
68
- error(" JCKUpdater script returned exit code 2, as no new update available. Gracefully stop the execution of pipeline." )
67
+ error (" JCKUpdater script returned exit code 2, as no new update available. Gracefully stop the execution of pipeline." )
69
68
currentBuild. result = " SUCCESS"
70
69
} else if (EXITCODE == 0 ) {
71
70
echo (" Script returned exit code 0, new update is available and PR is created." )
@@ -155,4 +154,3 @@ def createComment(comment,number) {
155
154
}
156
155
}
157
156
}
158
-
0 commit comments