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 sourceYou 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 NugetHostingPush with Symbol Package
dotnet nuget push MyPackage.1.0.0.nupkg \
--source NugetHosting \
--symbol-source NugetHostingInstall Packages
Add a package from NugetHosting to your project:
dotnet add package MyPrivatePackage --source NugetHostingOr restore all packages including from NugetHosting:
dotnet restoreRemove Source
If you need to remove the source:
dotnet nuget remove source NugetHosting