You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In a Windows CMD or PowerShell prompt, navigate to the WSL directory:
PS C:\Users\paulmedynski> D:
PS D:\> cd \home\paul\dev\NugetIssue
In this case, I have mapped the root filesystem of my WSL distro to D: in Windows, since CMD doesn't support UNC paths. Using the full UNC path in PowerShell exhibits the same behaviour.
Note that when the project lives on a native local Windows filesystem, NuGet considers the same set of config filenames as it does on Linux. It is only when accessing the project via a WSL UNC path that NuGet's behaviour restricts to "NuGet.Config".
Further technical details
WSL Linux:
$ dotnet --info
.NET SDK:
Version: 9.0.101
Commit: eedb237549
Workload version: 9.0.100-manifests.3068a692
MSBuild version: 17.12.12+1cce77968
Runtime Environment:
OS Name: debian
OS Version: 12
OS Platform: Linux
RID: linux-x64
Base Path: /usr/share/dotnet/sdk/9.0.101/
.NET workloads installed:
There are no installed workloads to display.
Configured to use loose manifests when installing new manifests.
Host:
Version: 9.0.0
Architecture: x64
Commit: 9d5a6a9aa4
.NET SDKs installed:
9.0.101 [/usr/share/dotnet/sdk]
.NET runtimes installed:
Microsoft.AspNetCore.App 9.0.0 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
Microsoft.NETCore.App 9.0.0 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
Other architectures found:
None
Environment variables:
Not set
global.json file:
/home/paul/dev/sandbox/ctaip/global.json
Learn more:
https://aka.ms/dotnet/info
Download .NET:
https://aka.ms/dotnet/download
Windows 11:
dotnet --info
.NET SDK:
Version: 9.0.101
Commit: eedb237549
Workload version: 9.0.100-manifests.3068a692
MSBuild version: 17.12.12+1cce77968
Runtime Environment:
OS Name: Windows
OS Version: 10.0.26100
OS Platform: Windows
RID: win-x64
Base Path: C:\Program Files\dotnet\sdk\9.0.101\
.NET workloads installed:
There are no installed workloads to display.
Configured to use loose manifests when installing new manifests.
Host:
Version: 9.0.0
Architecture: x64
Commit: 9d5a6a9aa4
.NET SDKs installed:
9.0.101 [C:\Program Files\dotnet\sdk]
.NET runtimes installed:
Microsoft.AspNetCore.App 9.0.0 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.NETCore.App 9.0.0 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.WindowsDesktop.App 9.0.0 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Other architectures found:
None
Environment variables:
Not set
global.json file:
C:\Users\paulmedynski\dev\ctaip\global.json
Learn more:
https://aka.ms/dotnet/info
Download .NET:
https://aka.ms/dotnet/download
The text was updated successfully, but these errors were encountered:
Thanks for creating this issue! We believe this issue is related to NuGet tooling, which is maintained by the NuGet team. Thus, we closed this one and encourage you to raise this issue in the NuGet repository instead. Don’t forget to check out NuGet’s contributing guide before submitting an issue!
If you believe this issue was closed out of error, please comment to let us know.
Describe the bug
On WSL Linux,
dotnet nuget config paths
will consider a file namednuget.config
,NuGet.config
, orNuGet.Config
at the solution/project root.On Windows, accessing the project via WSL UNC paths or mapped drives,
dotnet nuget config paths
will only consider a file namedNuGet.Config
.The CLI tools should be consistent across OSes regarding which NuGet config filenames are considered.
To Reproduce
In WSL, create a new project
Create a Nuget config file named
nuget.config
with the following content:In WSL, check that the NuGet config file will be considered:
In a Windows CMD or PowerShell prompt, navigate to the WSL directory:
In this case, I have mapped the root filesystem of my WSL distro to D: in Windows, since CMD doesn't support UNC paths. Using the full UNC path in PowerShell exhibits the same behaviour.
Check what config files NuGet will consider:
Rename the config file to "NuGet.Config":
Note that when the project lives on a native local Windows filesystem, NuGet considers the same set of config filenames as it does on Linux. It is only when accessing the project via a WSL UNC path that NuGet's behaviour restricts to "NuGet.Config".
Further technical details
WSL Linux:
Windows 11:
The text was updated successfully, but these errors were encountered: