The package manager for .NET
open sourceApache-2.0self-hostablefree
NuGet is the package manager for .NET: it defines how packages (.nupkg files of compiled code and a manifest) are created, hosted and consumed, and provides the tools for each role. The NuGet Gallery at nuget.org is the central public repository, and teams can host private feeds on Azure DevOps, a private network or a local folder. Packages are installed through the dotnet CLI, nuget.exe, MSBuild or Visual Studio's Package Manager, and one package can carry builds for several target frameworks. The client tools are open source under the .NET Foundation; Microsoft maintains the NuGet Gallery.
Ways to install
Package managers
Problems it solves
- add third-party libraries to my C# project without downloading DLLs by hand
- share reusable .NET code across my company's projects through a private package feed
- publish my .NET library so other developers can install it
- ship one .NET package that works on several target frameworks
- restore my .NET project's dependencies automatically when it builds on CI
- find open source .NET libraries for a job and see how widely each is used
- control which package sources our developers' machines can install .NET packages from
- install and update .NET packages inside Visual Studio without leaving the IDE
Features
- .nupkg packages of compiled code with a manifest
- NuGet Gallery at nuget.org as the central public repository
- private feeds on Azure DevOps, a private network or the local file system
- multi-targeting packages for several .NET target frameworks
- NuGet commands in the dotnet CLI on all platforms
- nuget.exe CLI for .NET Framework and non-SDK-style projects
- Package Manager UI and Package Manager Console in Visual Studio
- pack and restore through MSBuild
- configuration to limit which package sources a machine uses
Limitations
- nuget.exe doesn't run on macOS, Linux or Mono: on those, NuGet commands come with the dotnet CLI in the .NET SDK2
Capabilities
| Has a command line tool | plan not known |
|---|
Alternatives
The same job
These do what NuGet does.
- Apache Maven Apache Maven builds, tests, and documents Java projects from a single project object model (POM)
- npm The package manager for JavaScript