File tree Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -118,10 +118,14 @@ def cancel_previous_build() {
118118}
119119
120120def should_skip_ci (pr_number ) {
121- withCredentials([string(credentialsId : ' jenkins-reader-apache' , variable : ' TOKEN' )]) {
121+ withCredentials([usernamePassword(
122+ credentialsId : ' jenkins-reader-apache' ,
123+ usernameVariable : ' GITHUB_APP' ,
124+ passwordVariable : ' TOKEN' ,
125+ )]) {
122126 run_full_ci = sh (
123127 returnStatus : true ,
124- script : " ./tests/scripts/git_skip_ci.py '${ pr_number} '" ,
128+ script : " ./tests/scripts/git_skip_ci.py --pr '${ pr_number} '" ,
125129 label : ' Check if CI should be skipped' ,
126130 )
127131 }
@@ -164,11 +168,11 @@ stage('Sanity Check') {
164168 script : ' ./tests/scripts/git_change_docs.sh' ,
165169 label : " Check for docs only changes" ,
166170 )
171+ skip_ci = should_skip_ci(env. CHANGE_ID )
167172 sh (
168173 script : " ${ docker_run} ${ ci_lint} ./tests/scripts/task_lint.sh" ,
169174 label : " Run lint" ,
170175 )
171- skip_ci = should_skip_ci(env. CHANGE_ID )
172176 }
173177 }
174178 }
You can’t perform that action at this time.
0 commit comments