I have two identical replace statements in the azure pipeline yaml file
- script: echo ${{ replace('refs/heads/origin', 'refs/heads', 'origin') }}
- script: echo $[ replace('refs/heads/origin', 'refs/heads', 'origin') ]
except for one is a runtime expression while the other one is a compile time expression.
While the compile time expression works fine run time expression is giving me following error
line 1: replace('refs/heads/origin', 'refs/heads', 'origin') : syntax error in expression (error token is "('refs/heads/origin', 'refs/heads', 'origin') ")
How do I make runtime replace expression works fine?