Changeset ec5d599 for Jenkins/Distribute


Ignore:
Timestamp:
Dec 5, 2020, 8:48:42 AM (5 years ago)
Author:
Peter A. Buhr <pabuhr@…>
Branches:
ADT, arm-eh, ast-experimental, enum, forall-pointer-decay, jacob/cs343-translation, master, new-ast-unique-expr, pthread-emulation, qualifiedEnum
Children:
e91a255
Parents:
7c1144b (diff), ad915e0 (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.
Message:

Merge branch 'master' of plg.uwaterloo.ca:software/cfa/cfa-cc

File:
1 edited

Legend:

Unmodified
Added
Removed
  • Jenkins/Distribute

    r7c1144b rec5d599  
    2626                wrap([$class: 'TimestamperBuildWrapper']) {
    2727
    28                         final commit = prepare_build()
     28                        final commit, build
     29                        (commit, build) = prepare_build()
    2930
    3031                        node('x64') {
     
    3536
    3637                                Tools.Checkout( commit )
     38
     39                                final version = GetVersion( build )
    3740                        }
    3841
     
    7477// Main compilation routines
    7578//===========================================================================================================
     79def GetVersion(build) {
     80        final pver = sh(
     81                returnStdout: true,
     82                script: "sed 's/AC_INIT(\\[cfa-cc\\],\\[\\(.*\\)\\],\\[cforall@plg.uwaterloo.ca\\])/\\1/;t;d' ${SrcDir}/configure.ac"
     83        ).trim()
    7684
     85        final version = "${pver}.${build}"
    7786
    78 //Compilation script is done here but environnement set-up and error handling is done in main loop
    79 // def checkout() {
    80 //      build_stage('Checkout', true) {
    81 //              //checkout the source code and clean the repo
    82 //              final scmVars = checkout scm
    83 //              Settings.GitNewRef = scmVars.GIT_COMMIT
    84 //              Settings.GitOldRef = scmVars.GIT_PREVIOUS_COMMIT
     87        echo "Package Version: ${pver}"
     88        echo "Build   Version: ${build}"
     89        echo "Long    Version: ${version}"
    8590
    86 //              echo GitLogMessage()
    87 //      }
    88 // }
     91        return version
     92}
     93
    8994
    9095//===========================================================================================================
     
    107112                                        defaultValue: '',                                                               \
    108113                                ],                                                                                              \
     114                                [$class: 'StringParameterDefinition',                                           \
     115                                        description: 'Build Number to put into the version',                    \
     116                                        name: 'Build',                                                                  \
     117                                        defaultValue: '0',                                                              \
     118                                ],                                                                                              \
    109119                        ],
    110120                ]])
     
    121131        echo "Distributing git commit ${ref}"
    122132
    123         return params.GitRef
     133        return [params.GitRef, params.Build]
    124134}
    125135
Note: See TracChangeset for help on using the changeset viewer.