Changeset d4ba8e9 for Jenkinsfile
- Timestamp:
- Aug 2, 2018, 2:14:34 PM (6 years ago)
- Branches:
- ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, deferred_resn, demangler, enum, forall-pointer-decay, jacob/cs343-translation, jenkins-sandbox, master, new-ast, new-ast-unique-expr, no_list, persistent-indexer, pthread-emulation, qualifiedEnum
- Children:
- 40032ae
- Parents:
- 3f9876e
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
Jenkinsfile
r3f9876e rd4ba8e9 163 163 currentBuild.description = "${compiler.cc_name}:${arch_name}${full}" 164 164 165 echo currentBuild.changeSets166 167 165 echo """Compiler : ${compiler.cc_name} (${compiler.cpp_cc}/${compiler.cfa_cc}) 168 166 Architecture : ${arch_name} … … 174 172 Silent : ${ pSilent.toString() } 175 173 """ 174 175 176 //Since tokenizer doesn't work, figure stuff out from the environnement variables and command line 177 //Configurations for email format 178 def project_name = (env.JOB_NAME =~ /(.+)\/.+/)[0][1].toLowerCase() 179 180 def gitLog = 'Error retrieving git logs' 181 def gitDiff = 'Error retrieving git diff' 182 def gitUpdate = 'Error retrieving update' 183 184 try { 185 gitUpdate = gitBranchUpdate(gitRefOldValue, gitRefNewValue) 186 187 sh "git rev-list --format=short ${gitRefOldValue}...${gitRefNewValue} > GIT_LOG" 188 gitLog = readFile('GIT_LOG') 189 190 sh "git diff --stat ${gitRefNewValue} ${gitRefOldValue} > GIT_DIFF" 191 gitDiff = readFile('GIT_DIFF') 192 } 193 catch (Exception error) {} 194 195 def email_subject = "[${project_name} git][BUILD# ${env.BUILD_NUMBER} - ${status}] - branch ${env.BRANCH_NAME}" 196 def email_body = """This is an automated email from the Jenkins build machine. It was 197 generated because of a git hooks/post-receive script following 198 a ref change was pushed to the repository containing 199 the project "UNNAMED PROJECT". 200 201 The branch ${env.BRANCH_NAME} has been updated. 202 ${gitUpdate} 203 204 Check console output at ${env.BUILD_URL} to view the results. 205 206 - Status -------------------------------------------------------------- 207 208 BUILD# ${env.BUILD_NUMBER} - ${status} 209 210 - Log ----------------------------------------------------------------- 211 ${gitLog} 212 ----------------------------------------------------------------------- 213 Summary of changes: 214 ${gitDiff} 215 """ 216 217 echo email_body 176 218 } 177 219
Note: See TracChangeset
for help on using the changeset viewer.