Installing and using nuget

In Visual Studio, go to Tools / Extension manager. Select the Online Gallery, and type in ‘nuget’ in the search box:

nuget0

Click the Download button, and install Nuget Package Manager:

nuget1

nuget2

nuget3

You need to restart VIsual Studio now. After that, if you click on a solution, you can enable Nuget Package Restore:

nuget4

You will get the following message:

nuget5

If you click the Yes button, the Nuget Package Restore will make sure that if you build your application, it will automatically download all required packages needed by the solution:

nuget6

nuget7

Afterwards, a new solution folder ‘.nuget’ is created:

nuget8

To add a nuget package, for example the Specflow nuget, right click the solution and select ‘Manage NuGet Packages for Solution…’:

nuget9

Select ‘Online’, type in the nuget name and click on the Install button next to the nuget you want to install:

nuget10

nuget11

nuget12

If you then look in the references of your project, you will see that the assembly has been added:

nuget13

Now everyone will be kept up to date with the correct nugets and versions with every build of the solution.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s