Nuget related issues

Nuget is the platform for package management in the .NET SDK and used for installing DevPrime CLI.

A common mistake when trying to install DevPrime CLI is not having the default public nuget configuration in your sources list. Before proceeding, confirm that you have the most up-to-date version of .NET SDK (Windows, Linux, Mac).
dotnet --version

error NU1101: Unable to find package devprime.cli. No packages exist with this id in source(s): C:\Program Files\dotnet\sdk\NuGetFallbackFolder, Microsoft Visual Studio Offline Packages
Tool 'devprime.cli' failed to update due to the following:
The tool package could not be restored.
Tool 'devprime.cli' failed to install. This failure may have been caused by:

* You are attempting to install a preview release and did not use the --version option to specify the version.
* A package by this name was found, but it was not a .NET tool.
* The required NuGet feed cannot be accessed, perhaps because of an Internet connection problem.
* You mistyped the name of the tool.

For more reasons, including package naming enforcement, visit

Clearing the local nuget cache
dotnet nuget locals all --clear

Checking the sources at the local Nuget.
dotnet nuget list source

The result should look something like the example below indicating the Nuget Source as ‘Enabled’.

Registered Sources:
  1. [Enabled]
  2.  Microsoft Visual Studio Offline Packages [Enabled]
      C:\Program Files (x86)\Microsoft SDKs\NuGetPackages\

To remove a source just enter its name
dotnet nuget remove source

To add the source of the public nuget
dotnet nuget add source -n

To learn more:
Managing the global packages, caching, and temp folders

Last modified March 10, 2022 (3956d90)