66 - pwsh : |
77 git clone https://github.com/Azure/azure-sdk-tools.git $(Build.SourcesDirectory)/tools_repo
88 cd $(Build.SourcesDirectory)/tools_repo
9- git checkout 564ad63ae72d18422533fa1da9d396e7703c1cb5
9+ git checkout 35ad98f821913eb0e8872f861ee60589b563c865
1010 displayName: Setup Identity Resolver
1111
1212 - pwsh : |
13- $result = dotnet run -v q -- `
13+ dotnet run -v q -- `
1414 --aad-app-id-var APP_ID `
1515 --aad-app-secret-var APP_SECRET `
1616 --aad-tenant-var AAD_TENANT `
1717 --kusto-url-var KUSTO_URL `
1818 --kusto-database-var KUSTO_DB `
1919 --kusto-table-var KUSTO_TABLE `
20- --identity "$(Build.QueuedBy)"
21-
22- $resolvedIdentity = ""
23- try { $resolvedIdentity = $result[-1] | ConvertFrom-Json } catch {}
24-
25- if($resolvedIdentity) {
26- Write-Host $resolvedIdentity
27-
28- Write-Host "##vso[task.setvariable variable=${{ parameters.TargetVariable }}]$($resolvedIdentity.GithubUserName)"
29- }
30- else {
31- Write-Host "Unable to locate a github user for identity $(Build.QueuedBy)"
32- }
20+ --identity "$(Build.QueuedBy)" `
21+ --targetvar "${{ parameters.TargetVariable }}"
3322 displayName: 'Resolving Queuing User'
3423 continueOnError: true
3524 workingDirectory: $(Build.SourcesDirectory)/tools_repo/tools/notification-configuration/identity-resolver
@@ -45,10 +34,12 @@ steps:
4534 Remove-Item -Force -Recurse $(Build.SourcesDirectory)/tools_repo
4635 displayName: Clean Up Cloned Tools Repo
4736
48- - pwsh : |
49- $originalValue = "$(${{ parameters.TargetVariable }})"
50- $result = $(Build.SourcesDirectory)/eng/common/scripts/get-codeowners.ps1 -TargetDirectory /sdk/${{ parameters.ServiceDirectory }}/ -RootDirectory $(Build.SourcesDirectory)
51- if ($result) {
52- Write-Host "##vso[task.setvariable variable=${{ parameters.TargetVariable }}]$originalValue,$result"
53- }
54- displayName: Add CodeOwners if Present
37+ - task : PowerShell@2
38+ displayName : Add CodeOwners if Present
39+ inputs :
40+ pwsh : true
41+ filePath : $(Build.SourcesDirectory)/eng/common/scripts/get-codeowners.ps1
42+ arguments : >
43+ -TargetDirectory "/sdk/${{ parameters.ServiceDirectory }}/"
44+ -RootDirectory "$(Build.SourcesDirectory)"
45+ -VsoVariable "${{ parameters.TargetVariable }}"
0 commit comments