Skip to content

Commit

Permalink
Use Nuget config file (#3112)
Browse files Browse the repository at this point in the history
* Use nuget config

* Use feed while building

* Use nuget config

* push location

---------

Co-authored-by: Jean-Marc Prieur <[email protected]>
  • Loading branch information
SaurabhMSFT and jmprieur authored Oct 28, 2024
1 parent 153cb3b commit 86a35af
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions build/template-restore-build-MSIdentityWeb.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,19 +12,23 @@ steps:
displayName: 'Install wasm-tools'

- powershell: |
Push-Location $(IdWebSourceDir)
$nugetSourceIsExternal = (dotnet nuget list source --format Short).Contains("https://api.nuget.org/v3/index.json")
if ($nugetSourceIsExternal) {
dotnet nuget remove source NuGet
dotnet nuget add source https://identitydivision.pkgs.visualstudio.com/_packaging/IDDP/nuget/v3/index.json -n IDDP
dotnet nuget list source
}
Pop-Location
displayName: 'Remove external "NuGet" Source and add "IDDP artifacts" as a NuGet Source, if needed.'

- task: DotNetCoreCLI@2
displayName: 'Build solution Microsoft.Identity.Web.sln'
inputs:
command: 'custom'
custom: 'build'
feedsToUse: 'config'
nugetConfigPath: NuGet.config
projects: '$(IdWebSourceDir)Microsoft.Identity.Web.sln'
arguments: '-p:configuration=${{ parameters.BuildConfiguration }} -p:RunCodeAnalysis=true -p:MicrosoftIdentityWebVersion=${{ parameters.MicrosoftIdentityWebVersion }} -p:SourceLinkCreate=true'

Expand Down

0 comments on commit 86a35af

Please sign in to comment.