Skip to content

Commit

Permalink
Merge "FABN-1051 Update pipeline script"
Browse files Browse the repository at this point in the history
  • Loading branch information
andrew-coleman authored and Gerrit Code Review committed Dec 6, 2018
2 parents afae931 + d664de0 commit c52319a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions Jenkinsfile.x
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,13 @@ node ('hyp-x') { // trigger build on x86_64 node
env.PROJECT_DIR = "gopath/src/github.com/hyperledger"
env.GOPATH = "$WORKSPACE/gopath"
env.PATH = "$GOPATH/bin:/usr/local/bin:/usr/bin:/usr/local/sbin:/usr/sbin:${nodeHome}/bin:$PATH"
def REFSPEC = sh(returnStdout: true, script: 'echo ${JOB_NAME} | grep "verify"').trim()
def jobname = sh(returnStdout: true, script: 'echo ${JOB_NAME} | grep "verify" && echo patchset || echo merge').trim()
def failure_stage = "none"
// delete working directory
deleteDir()
stage("Fetch Patchset") { // fetch gerrit refspec on latest commit
stage("Fetch Patchset") {
try {
if (REFSPEC != null) {
if (jobname == "patchset") {
println "$GERRIT_REFSPEC"
println "$GERRIT_BRANCH"
checkout([
Expand Down
4 changes: 2 additions & 2 deletions Jenkinsfile.z
Original file line number Diff line number Diff line change
Expand Up @@ -18,14 +18,14 @@ node('hyp-z') {
env.PROJECT_DIR = "gopath/src/github.com/hyperledger"
env.GOPATH = "$WORKSPACE/gopath"
env.PATH = "$GOPATH/bin:/usr/local/bin:/usr/bin:/usr/local/sbin:/usr/sbin:~/npm/bin:/home/jenkins/.nvm/versions/node/v${NODE_VER}/bin:$PATH"
def REFSPEC = sh(returnStdout: true, script: 'echo ${JOB_NAME} | grep "verify"').trim()
def jobname = sh(returnStdout: true, script: 'echo ${JOB_NAME} | grep "verify" && echo patchset || echo merge').trim()
def failure_stage = "none"
// delete working directory
deleteDir()
stage("Fetch Patchset") { // fetch gerrit refspec on latest commit
cleanWs()
try {
if (REFSPEC != null) {
if (jobname == "patchset") {
println "$GERRIT_REFSPEC"
println "$GERRIT_BRANCH"
checkout([
Expand Down

0 comments on commit c52319a

Please sign in to comment.