I have build a yaml pipeline which has multiple stages in them. To ensure all the stages are using the same git tag, I am trying to display the git tag in the displayName of each stage.
I have a job within the stage which goes and finds the git tag
stages:
- stage : stageA
jobs:
- job: Tag
steps:
- bash: |
tag=`git describe --tags --abbrev=0` && echo "##vso[task.setvariable variable=version_tag;isOutput=true]$tag"
echo "$tag"
name: setTag
How can I use the $tag under displayName in the next stage of the pipeline?
