azure pipeline vairable not working

Guo Cindy 1 Reputation point
2021-06-06T02:42:34.843+00:00

I tested the following pipeline yml file and get 1 when echo ${<!-- -->{ variables.isTestA }}. But why the result is false when I compare ${<!-- -->{ variables.isTestA }} and 1?


variables:
isTestA: $(deploy_env)

trigger:

  • master

pool: 'Default'

steps:

  • script: echo ${<!-- -->{ variables.isTestA }}
    displayName: 'Run a one-line script'
  • script: |
    echo working
    condition: eq('${<!-- -->{ variables.isTestA }}', '1')
Not Monitored
Not Monitored
Tag not monitored by Microsoft.
43,238 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Anonymous
    2021-06-06T02:55:39.57+00:00

    Devops / TFS is not currently supported here on QnA. The product group for Azure DevOps / TFS actively monitors questions over at
    https://developercommunity.visualstudio.com/report?space=21&entry=problem
    https://developercommunity.visualstudio.com/report?space=22&entry=problem

    --please don't forget to upvote and Accept as answer if the reply is helpful--

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.