Let's use the same NugetPackageRestoreEx console application created in the previous post. The project has Ninject nuget package referenced.

When the package was installed to the project, the project was targeting .net framework 4.5, hence all the required references were also targeting the same framework version. The world is really a happy place.
Now let us retarget the project to .net framework 3.5 from the property page of the project.

As we retarget the project, the nuget package references might become invalid. Nuget 2.7 added a new feature to help in this case. As soon as we retarget the project, there is a build error generated and the Errors List window is displayed with the details about the possible error.

The update has also added a new attribute to the packages.config schema. This is also notified in packages.config stating that you would require a re-installation of this package as per the updated targeted framework version of the project.

The error is transformed into a warning as we rebuild the project. Since the developer has been notified with the possible risk, it should be fine.

Download
No comments:
Post a Comment