🌐 Documentation is currently available in English only. We're working on translations.

Home / Docs / NuGet Guide / dotnet CLI

dotnet CLI

Use the dotnet command-line interface to manage packages with NugetHosting.

⏱️ 4 min read

Add Package Source

Add NugetHosting as a NuGet package source:

dotnet nuget add source https://nuget.nugethosting.com/v3/index.json \
  --name NugetHosting \
  --username api \
  --password YOUR_API_TOKEN \
  --store-password-in-clear-text

💡 Note: Replace YOUR_API_TOKEN with your actual API token from the Tokens page.

List Package Sources

View all configured NuGet sources:

dotnet nuget list source

You should see NugetHosting in the list of registered sources.

Push Packages

Upload a package to your private feed:

dotnet nuget push MyPackage.1.0.0.nupkg --source NugetHosting

Push with Symbol Package

dotnet nuget push MyPackage.1.0.0.nupkg \
  --source NugetHosting \
  --symbol-source NugetHosting

Install Packages

Add a package from NugetHosting to your project:

dotnet add package MyPrivatePackage --source NugetHosting

Or restore all packages including from NugetHosting:

dotnet restore

Remove Source

If you need to remove the source:

dotnet nuget remove source NugetHosting
Was this page helpful?