Using Jenkins Version Environment Variable in the MSBuild step

后端 未结 4 861
情深已故
情深已故 2021-02-05 23:45

I\'m currently using the Jenkins \"Version Number Plug-In\" to set an Environment Variable for build version. This works fine within jenkins but i need a way to pass this to MSB

4条回答
  •  萌比男神i
    2021-02-06 00:30

    Environment Variable Name should be written without the percent-marks ('%'), like this:

    VERSION
    

    apart from that, I think you are good to go.

    May also consider changing
    ${BUILDS_ALL_TIME}
    to
    ${BUILDS_ALL_TIME, XX}

    (this will enforce a two-digit build-number with leading zeros)

提交回复
热议问题