问题
I searched all the docs about Output Variables are for build pipeline and only told me how to set in .yaml. But how to use it in release pipeline?
Supposed I have 2 variables $abc="123" $def="456" in step Login. How to set them in below text box? and How to use them in step Deploy?
回答1:
Some tasks define output variables
For brief text, it represents the follow scripts:
echo "##vso[task.setvariable variable=abc;isOutput=true]123"
Just specify the reference name in the blank of task, and then, you can call this output variable abc
by using the format: <reference name>.<variable name>
.
For example, if you specify the reference name as mycustom
, just call the output variable by using $(mycustom.abc)
.
来源:https://stackoverflow.com/questions/59369619/how-to-use-output-variables-in-release-pipeline