How to force Nuget to install package

Topics: General
Jun 13, 2014 at 7:50 PM
We have the following folder structure in TFS and it is mapped to my workspace on C:\

$/MyProjects/Portal/Dev/1.10/Library/Server ( This folder holds the all the referenced assemblies including EF5)
$/MyProjects/Portal/Dev/1.10/MySolution1/MySolution1.sln
$/MyProjects /Portal/Dev/1.10/Framework/Framework/Framework.sln


Both the solutions are currently referencing EF5 assemblies from Library/Server folder. We are planning to upgrade from EF5 to EF6 using NuGet. We want EF6 package to be installed in /Library/Server. Here are the steps I followed

1> Create NuGet.config file in C\MyProjects\Portal\Dev\1.10\MySolution1/ and add <add key="repositoryPath" value="..\Libraries\Server\packages" />
2> Open MySolution1 in VS go to “Manage Nuget Packages for Solution” and then Install EF6
3> Nuget removes all old references and add new references to EF6
4> Now Create one more Nuget.config in C:\MyProjects\Portal\Dev\1.10\Framework\Framework\ and add <add key="repositoryPath" value="....\Libraries\Server\packages" />

5> Now open Framework.sln in VS go to “Manage Nuget Packages for Solution”
6> Nuget shows green check mark and says its already installed when its not. ( looks like Nuget only checks if the package folder exists in the repositoryPath but doesn’t actually check if the projects are actually referencing it from that package folder)


How do I force Nuget to install package in Framework solution