source: Jenkinsfile @ 63fe9f1d

ADTaaron-thesisarm-ehast-experimentalcleanup-dtorsctordeferred_resndemanglerenumforall-pointer-decaygc_noraiijacob/cs343-translationjenkins-sandboxmemorynew-astnew-ast-unique-exprnew-envno_listpersistent-indexerpthread-emulationqualifiedEnumresolv-newwith_gc
Last change on this file since 63fe9f1d was 63fe9f1d, checked in by Thierry Delisle <tdelisle@…>, 8 years ago

fixed error in jenkins file

  • Property mode set to 100644
File size: 1.9 KB
Line 
1
2//Configurations for email format
3def email_subject_template = '[$PROJECT_NAME git] - branch $GIT_BRANCH - Build # $BUILD_NUMBER - $BUILD_STATUS!'
4def email_body_template = '''This is an automated email from the Jenkins build machine. It was
5generated because of a git hooks/post-receive script following
6a ref change was pushed to the repository containing
7the project "UNNAMED PROJECT".
8
9The branch $GIT_BRANCH has been updated
10       via  $GIT_COMMIT (commit)
11      from  $GIT_PREVIOUS_COMMIT (commit)
12
13Those revisions listed above that are new to this repository have
14not appeared on any other notification email; so we list those
15revisions in full, below.
16
17Check console output at $BUILD_URL to view the results.'''
18
19node ('master'){
20        stage 'Build'
21
22        sh 'printenv'
23
24        //clean the repo and checkout the source code
25        checkout scm
26
27        //Configurations for email format
28
29        //Since tokenizer doesn't work, figure stuff out from the environnement variables and command line
30        def project_name = (env.JOB_NAME =~ /(.+)\/.+/)[0][1]
31
32        def email_subject = "[${project_name} git] - branch ${env.BRANCH_NAME} - Build # ${env.BUILD_NUMBER} - BUILD_STATUS!"
33        def email_body = """This is an automated email from the Jenkins build machine. It was
34        generated because of a git hooks/post-receive script following
35        a ref change was pushed to the repository containing
36        the project "UNNAMED PROJECT".
37
38        The branch ${env.BRANCH_NAME} has been updated
39               via  GIT_COMMIT (commit)
40              from  GIT_PREVIOUS_COMMIT (commit)
41
42        Those revisions listed above that are new to this repository have
43        not appeared on any other notification email; so we list those
44        revisions in full, below.
45
46        Check console output at ${env.BUILD_URL} to view the results."""
47
48        def email_to = 'tdelisle@uwaterloo.ca'
49
50        //configure the conpilation
51        sh 'CC=gcc-4.9 CXX=g++-4.9 ./configure'
52
53        //build
54        sh 'make -j 8'
55
56        //send email notification
57        emailext body: email_body, subject: email_subject, to: email_to, attachLog: true
58 }
Note: See TracBrowser for help on using the repository browser.