Use VSTS-specific branch name for PRs if available

This commit is contained in:
Daniel Cazzulino 2017-12-04 15:56:30 -03:00
Родитель 0b327af241
Коммит 73746296c1
1 изменённых файлов: 2 добавлений и 1 удалений

Просмотреть файл

@ -42,7 +42,8 @@ AssemblyVersion=$(AssemblyVersion)" />
<GitSemVerDashLabel Condition="'$(APPVEYOR_PULL_REQUEST_NUMBER)' != ''">$(GitSemVerDashLabel)-pr$(APPVEYOR_PULL_REQUEST_NUMBER)</GitSemVerDashLabel>
<!-- Adjust branch name to CI provided value if available -->
<GitBranch Condition="'$(BUILD_SOURCEBRANCHNAME)' != ''">$(BUILD_SOURCEBRANCHNAME)</GitBranch>
<GitBranch Condition="'$(SYSTEM_PULLREQUEST_TARGETBRANCH)' != ''">$(SYSTEM_PULLREQUEST_TARGETBRANCH)</GitBranch>
<GitBranch Condition="'$(SYSTEM_PULLREQUEST_TARGETBRANCH)' == '' and '$(BUILD_SOURCEBRANCHNAME)' != ''">$(BUILD_SOURCEBRANCHNAME)</GitBranch>
<GitBranch Condition="'$(APPVEYOR_REPO_BRANCH)' != ''">$(APPVEYOR_REPO_BRANCH)</GitBranch>
<!-- NOTE: build metadata does not affect version matching, so even if you work from a different branch+commit that gets