I need to email a VS 2010 solution to a few people. Some of the projects have NuGet references. If the recipients have VS 2010 RTM installed, will those projects compile?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Summary
If you have used the NuGetPowerTools and have enabled package restore (Enable-PackageRestore command), then those packages will be fetched in a pre-build step.
All you need to do is to send the zipped solution, including the $(SolutionDir)\.nuget folder.
Detailed explanation
Because you have run the Enable-PackageRestore command, all your project files (which are MSBuild files) referenced by the solution, will import $(SolutionDir)\.nuget\NuGet.targets file, which in turn also imports the $(SolutionDir)\.nuget\NuGet.Settings.targets file. These MSBuild tasks call the $(SolutionDir).nuget\nuget.exe command line tool in a pre-build step to fetch all required packages. This way, your packages are still fetched from the package source you defined in the NuGet.Settings.targets file (default is nuget.org feed), without requiring everyone to install the NuGet VisualStudio extension.