I have this code inside my YAML file for an Azure pipeline:
steps:
- bash: |
echo $(date +%Y)
echo "##vso[task.setvariable variable=buildName]$(date +%Y)_$(date +%m)_$(Build.BuildNumber)_v3.7"
echo $BUILDNAME
The first echo correctly prints 2020, but the third print $(date +%Y)_$(date +%m)_4728573844_v3.7. As you can see, here the year and month are not translated into values. Why?
