Skip to content

Commit fa86030

Browse files
CI: Deploy pipeline: added missing script block (#1763) (#1764)
Co-authored-by: Michael Biarnés Kiefer <mbiarnes@redhat.com>
1 parent da9be74 commit fa86030

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

.ci/jenkins/Jenkinsfile.deploy

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -85,12 +85,14 @@ pipeline {
8585
expression { return isRelease() || isCreatePr() }
8686
}
8787
steps {
88-
dir(getRepoName()) {
89-
if (githubscm.isBranchExist('origin',getPRBranch())) {
90-
githubscm.removeRemoteBranch('origin', getPRBranch())
88+
script {
89+
dir(getRepoName()) {
90+
if (githubscm.isBranchExist('origin',getPRBranch())) {
91+
githubscm.removeRemoteBranch('origin', getPRBranch())
92+
}
93+
githubscm.createBranch(getPRBranch())
9194
}
92-
githubscm.createBranch(getPRBranch())
93-
}
95+
}
9496
}
9597
}
9698
stage('Update project version') {

0 commit comments

Comments
 (0)