Skip to content

Reading the pipeline variables inside the handlebars template #983

Answered by rfennell
mlop3s asked this question in Q&A
Discussion options

You must be logged in to vote

No there is way to read environmental variables on the template. However, if it is semver you want why not set the build name using the GitVersion tasks.

This is the way I do it, I use the following at the top of my build

name: $(Build.DefinitionName)_$(GitVersion.FullSemVer)

And then can use this in the templates as

Build {{buildDetails.buildNumber}}

Replies: 1 comment 4 replies

Comment options

You must be logged in to vote
4 replies
@mlop3s
Comment options

@rfennell
Comment options

@markbangert
Comment options

@ejwill
Comment options

Answer selected by mlop3s
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment