Skip to content

Commit 103d4f7

Browse files
ci: add nuget.org to the PowerShellEditorServices sources
Temporary workaround: PSES's nuget.config only lists an Azure DevOps feed, which returns 401 (Unauthorized) for anonymous downloads, so CI fails while restoring the .NET reference packs before any tests run. Drop this once that is fixed upstream.
1 parent 0c38bd9 commit 103d4f7

1 file changed

Lines changed: 19 additions & 0 deletions

File tree

‎.github/workflows/ci-test.yml‎

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,25 @@ jobs:
3030
repository: PowerShell/PowerShellEditorServices
3131
path: PowerShellEditorServices
3232

33+
# TODO: Drop this once PowerShellEditorServices can restore again. Its
34+
# nuget.config only lists an Azure DevOps feed, which returns 401
35+
# (Unauthorized) for anonymous downloads, so restoring the .NET reference
36+
# packs fails before any of our tests run. Add nuget.org as a source.
37+
- name: Add nuget.org to the PowerShellEditorServices sources
38+
shell: pwsh
39+
run: |
40+
$config = @(
41+
'<?xml version="1.0" encoding="utf-8"?>'
42+
'<configuration>'
43+
' <packageSources>'
44+
' <clear />'
45+
' <add key="PowerShellCore_PublicPackages" value="https://pkgs.dev.azure.com/powershell/PowerShell/_packaging/powershell/nuget/v3/index.json" />'
46+
' <add key="nuget.org" value="https://api.nuget.org/v3/index.json" />'
47+
' </packageSources>'
48+
'</configuration>'
49+
)
50+
Set-Content -Path PowerShellEditorServices/nuget.config -Value $config
51+
3352
- name: Checkout vscode-powershell
3453
uses: actions/checkout@v7
3554
with:

0 commit comments

Comments
 (0)