How to Fix Your NuGet Config File
If you cannot restore your NuGet files because of a missing entry for NuGet.org or any other problem, open the root folder of your project and run this command:
1 |
dotnet new nugetconfig |
This will create a new nuget.config file with this content:
1 2 3 4 5 6 7 8 |
<?xml version="1.0" encoding="utf-8"?> <configuration> <packageSources> <!--To inherit the global NuGet package sources remove the <clear/> line below --> <clear /> <add key="nuget" value="https://api.nuget.org/v3/index.json" /> </packageSources> </configuration> |
From here on, you can add your additional feeds and Visual Studio should recover …