From b684d68b98febdce09d8894eb31e7ce60e42d16c Mon Sep 17 00:00:00 2001 From: Angela Tran Date: Thu, 17 Aug 2023 20:33:21 +0000 Subject: [PATCH] chore: test out setting variable to say build is for a tag --- terraform/pipeline/azure-pipelines.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/terraform/pipeline/azure-pipelines.yml b/terraform/pipeline/azure-pipelines.yml index 71c7ede7..e9507520 100644 --- a/terraform/pipeline/azure-pipelines.yml +++ b/terraform/pipeline/azure-pipelines.yml @@ -24,9 +24,13 @@ stages: value: $[variables['System.PullRequest.SourceBranch']] - name: INDIVIDUAL_SOURCE value: $[variables['Build.SourceBranchName']] + - name: IS_TAG + value: $[startsWith(variables['Build.SourceBranch'], 'refs/tags/')] - name: TARGET value: $[variables['System.PullRequest.TargetBranch']] steps: + - bash: | + echo $(IS_TAG) # set the workspace variable at runtime (rather than build time) so that all the necessary variables are available, and we can use Python # https://learn.microsoft.com/en-us/azure/devops/pipelines/process/set-variables-scripts?view=azure-devops&tabs=bash#about-tasksetvariable - bash: |