We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d058daf commit f08c94fCopy full SHA for f08c94f
azure-pipelines.yml
@@ -70,6 +70,12 @@ variables:
70
value: '$(Build.QueuedBy)'
71
- name: 'timestamper'
72
value: ${{ parameters.timestamper }}
73
+- ${{ if startsWith(variables['Build.SourceBranch'], 'refs/heads/') }}:
74
+ - name: 'branchName'
75
+ value: $[ replace(variables['Build.SourceBranch'], 'refs/heads/', '') ]
76
+- ${{ if startsWith(variables['Build.SourceBranch'], 'refs/pull/') }}:
77
78
+ value: $[ replace(variables['System.PullRequest.TargetBranch'], 'refs/heads/', '') ]
79
80
steps:
81
- checkout: self
0 commit comments