Forum Discussion
ariyolo
Jan 04, 2022Copper Contributor
Multi repositories in Variables
Hello i have multi repositories:
code: the source code of application android
tool: pipeline.yml
In pipeline.yml i wrote below, so i have variables $branch which contain branch the code
variables:
branch: $[ resources.repositories['code'].ref ]
How i can use if else variables refer to $branch variables, i have try like this and not working
jobs:
- job:
variables:
${{ if eq(variables.branch, 'master') }}:
AssembleTask: assembleProdRelease
${{ elseif eq(variables.branch, 'release') }}:
AssembleTask: assembleProdRelease
${{ elseif eq(variables.branch, 'develop') }}:
AssembleTask: assembleSitDebug
I run the pipeline refer to "tool" repository.
No RepliesBe the first to reply