add refs to resources

This commit is contained in:
MilenaHristova 2023-02-02 15:01:28 +01:00
parent 48873c2344
commit 439d38946c
2 changed files with 16 additions and 0 deletions

View file

@ -37,6 +37,21 @@ variables:
/p:DotNetRuntimeSourceFeedKey=$(dotnetbuilds-internal-container-read-token-base64)
/p:dotnetbuilds-internal-container-read-token-base64=$(dotnetbuilds-internal-container-read-token-base64)
- ${{ if eq(variables['Build.Reason'], 'PullRequest') }}:
- name: VmrRef
value: $(System.PullRequest.TargetBranch)
- ${{ else }}:
- name: VmrRef
value: 'refs/heads/main'
resources:
repositories:
- repository: vmr
type: github
name: dotnet/dotnet
endpoint: dotnet
ref: $(VmrRef)
stages:
- stage: Build
jobs:

View file

@ -13,6 +13,7 @@ resources:
type: github
name: dotnet/dotnet
endpoint: dotnet
ref: $(Build.SourceBranch)
parameters:
- name: vmrBranch