1

Hi I have created very basic class library project and created .nupkg. I am trying to push package using the below command nuget.exe push -Source -ApiKey az . To my bad whenever I do it says

'nuget.exe' is not recognized as an internal or external command,
operable program or batch file.

When I search over the internet It says to download nuget.exe so I navigated to nuget download page. To my bad It says nuget.exe comes by default with VS 2019. I am using VS 2019. I am not able to understand whats wrong with these documentation Or I am misunderstanding all these documentations? Can someone help me to identify where should I download or If I exist where is the path and how should I run above command? Any help would be appreciated. Thanks

1
  • Agree with Martin's answer that nuget.exe can be downloaded from nuget.org/downloads under "Windows x86 Commandline". After you download it, you could open command line window and switch to its download directory to run this command nuget.exe push -Source -ApiKey az. See: Publish a NuGet package using the command line for more guidance. Commented Apr 15, 2021 at 9:52

1 Answer 1

3

nuget.exe can be downloaded from https://www.nuget.org/downloads under "Windows x86 Commandline".

Visual Studio 2019 Contains all NuGet tools, so there are no VSIX packages to install for NuGet support as in previous VS versions.

Do note that depending on your selected workloads, Visual Studio will also install the dotnet CLI as part of the .NET SDK. So you can also use dotnet nuget push, which has slightly different arguments (--source and --api-key, check with dotnet nuget push -h)

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.