Quickstart: Create and publish a NuGet …
https://learn.microsoft.com/en-us/nuget/quickstart/create-and-publish-a-package-using-visual-studio
To create a NuGet package from your project, follow these steps: Select Build > Configuration Manager, and then set the Active solution configuration to Release. Select the AppLogger project in Solution Explorer, then select Pack. Visual Studio builds the project and creates the .nupkg file. Select Build > Configuration Manager, and then set the Active solution configuration to Release. Select the project you want to create a NuGet package for in Solution Explorer. Select Pack.
Select Build > Configuration Manager, and then set the Active solution configuration to Release.
Select the project you want to create a NuGet package for in Solution Explorer.
Select Pack.
DA: 8 PA: 30 MOZ Rank: 76