Tuesday, June 16, 2015

Creating Nuget Packages using Visual Studio 2015

If you have ever created a nuget package you know how annoying it is. Using the nuget command line to pack the project and then create the .nuspec file and then build it for the desired frameworks.
Visual Studio 2015 (currently RC) lets you create nuget packages extremely easy!
First create a new Class Library project:
clip_image002
Notice that it is under ‘Web’ category.
clip_image004
Now we’ll enable the nugget package creation just as written in the comments above.
clip_image006
I just love their UX in this window.
Now we’ll need to fill the package details in the project.json file.
clip_image007
The project.json is almost the same as the .nuspec file. We can include the package dependencies and the target frameworks.
Now if we compile the project and navigate to the solution directory we’ll see the nuget package in the artifacts folder.
clip_image008
clip_image009
Good luck Smile














No comments:

Post a Comment