Changeset c8c03683 for Jenkinsfile
- Timestamp:
- Jun 14, 2016, 12:53:26 PM (8 years ago)
- Branches:
- ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, ctor, deferred_resn, demangler, enum, forall-pointer-decay, gc_noraii, jacob/cs343-translation, jenkins-sandbox, master, memory, new-ast, new-ast-unique-expr, new-env, no_list, persistent-indexer, pthread-emulation, qualifiedEnum, resolv-new, with_gc
- Children:
- 7ff30d07
- Parents:
- e04ef3a (diff), d14d96a (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
Jenkinsfile
re04ef3a rc8c03683 36 36 37 37 def push_build() { 38 build_stage 'Push' 39 40 sh 'git remote add DoLang git@gitlab.do-lang.org:internal/cfa-cc.git' 41 sh 'git push DoLang master' 38 //Don't use the build_stage function which outputs the compiler 39 stage 'Push' 40 41 status_prefix = 'Push' 42 43 def out_dir = pwd tmp: true 44 sh "mkdir -p ${out_dir}" 45 46 //parse git logs to find what changed 47 sh "git remote > ${out_dir}/GIT_REMOTE" 48 git_remote = readFile("${out_dir}/GIT_REMOTE") 49 remoteDoLangExists = git_remote.contains("DoLang") 50 51 if( !remoteDoLangExists ) { 52 sh 'git remote add DoLang git@gitlab.do-lang.org:internal/cfa-cc.git' 53 } 54 55 sh "git push DoLang ${gitRefNewValue}:master" 42 56 } 43 57 … … 74 88 def collect_git_info() { 75 89 90 //create the temporary output directory in case it doesn't already exist 76 91 def out_dir = pwd tmp: true 92 sh "mkdir -p ${out_dir}" 93 94 //parse git logs to find what changed 77 95 gitRefName = env.BRANCH_NAME 78 96 dir("../${gitRefName}@script") { … … 89 107 node ('master'){ 90 108 109 boolean doPromoteBuild2DoLang 91 110 def err = null 92 111 def log_needed = false … … 113 132 ]]) 114 133 115 echo "FULL BUILD = ${promoteBuild2DoLang}" 134 doPromoteBuild2DoLang = promoteBuild2DoLang == 'true' 135 136 echo "FULL BUILD = ${doPromoteBuild2DoLang}" 116 137 117 138 //Compile using gcc-4.9 … … 127 148 cfa_build() 128 149 129 if( promote_build) {150 if( doPromoteBuild2DoLang ) { 130 151 push_build() 131 152 } … … 149 170 finally { 150 171 //Send email with final results 151 notify_result( promote_build, err != null, currentBuild.result, log_needed)172 notify_result(doPromoteBuild2DoLang, err, currentBuild.result, log_needed) 152 173 153 174 /* Must re-throw exception to propagate error */ … … 161 182 //Routine responsible of sending the email notification once the build is completed 162 183 //=========================================================================================================== 163 def promote_email(boolean promote, boolean success, String status, boolean log) {184 def notify_result(boolean promote, Exception err, String status, boolean log) { 164 185 if(promote) { 165 if( !success) {186 if( err ) { 166 187 promote_email(status) 167 188 }
Note: See TracChangeset
for help on using the changeset viewer.