File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -35,3 +35,18 @@ Write-Host "Created $rootNpmrc"
3535$rushNpmrc = Join-Path $SourcesDirectory " autorest.powershell/common/config/rush/.npmrc"
3636Set-Content - Path $rushNpmrc - Value $npmrcContent - NoNewline
3737Write-Host " Updated $rushNpmrc "
38+
39+ # Create NuGet.config to redirect dotnet restore to the private feed
40+ $nugetFeed = $Registry -replace " /npm/registry/$" , " /nuget/v3/index.json"
41+ $nugetConfig = @"
42+ <?xml version="1.0" encoding="utf-8"?>
43+ <configuration>
44+ <packageSources>
45+ <clear />
46+ <add key="PowerShell_V2_Build" value="$nugetFeed " />
47+ </packageSources>
48+ </configuration>
49+ "@
50+ $nugetConfigPath = Join-Path $SourcesDirectory " NuGet.config"
51+ Set-Content - Path $nugetConfigPath - Value $nugetConfig - NoNewline
52+ Write-Host " Created $nugetConfigPath "
You can’t perform that action at this time.
0 commit comments