BT

New Early adopter or innovator? InfoQ has been working on some new features for you. Learn more

NuGet 2.0 Brings New Package Conventions, Still no Mono, Python, or C++ Support

| by Jonathan Allen Follow 131 Followers on Jul 01, 2012. Estimated reading time: 1 minute |

Despite the version tag, NuGet 2.0 is actually a fairly minor release. Aside from improved tab completion in the package manager console, most of the changes revolve around packaging conventions.

In the past, the only folder that supported framework specific folders was “lib”. With this version, “content” and “tools” can likewise be divided. Files in the content folder are copied directly into the project’s root. This is used for license files, images, and anything else needed by the project except for assemblies.

The tools folder is primarily used for the package’s install and uninstall scripts. These scripts are written in PowerShell and executed by the package manager when the package is added to a project. One of the parameters the script receives is $project, which is a reference to Visual Studio’s EnvDTE project object. With it you can do pretty much anything you can with a normal VS plugin or macro.

Another change is the way that package dependencies are registered. In the past package dependencies were all or nothing. Now you can group dependencies by target framework, where in each group is tagged with a specific framework. A default dependency group can also be created, but this is only used if there are no other matches.

NuGet is still a tool explicitly for C#, VB, and F# tool. There is no support for IronPython C++/CLI, or Mono projects. Since you cannot download NuGet packages directly from NuGet.org, developers using these project types need to use the command line tool.

Rate this Article

Adoption Stage
Style

Hello stranger!

You need to Register an InfoQ account or or login to post comments. But there's so much more behind being registered.

Get the most out of the InfoQ experience.

Tell us what you think

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Email me replies to any of my messages in this thread
Community comments

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Email me replies to any of my messages in this thread

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Email me replies to any of my messages in this thread

Discuss

Login to InfoQ to interact with what matters most to you.


Recover your password...

Follow

Follow your favorite topics and editors

Quick overview of most important highlights in the industry and on the site.

Like

More signal, less noise

Build your own feed by choosing topics you want to read about and editors you want to hear from.

Notifications

Stay up-to-date

Set up your notifications and don't miss out on content that matters to you

BT