I currently got stuck into following problem:
A collegue of mine has ported one of his C# projects to the new csproj format (see http://www.natemcmaster.com/blog/2017/03/09/vs2015-to-vs2017-upgrade/ for details). Using Visual Studio 2017 building works. Unfortunately I am using MSBuild in some console application for compiling these projects too and it seems that the current MSBuild version that is shipped with Visual Studio 2017 gets into trouble when using the new "PackageReference" keyword.
Does anyone has a hint for me?
Update:
Here are some more details:
I have a console application where I am referencing some "Microsoft.Build" assemblies from "Program Files (x86)\Microsoft Visual Studio\2017\Professional\MSBuild\15.0\Bin". I am using the "BuildManager" for building the code. My collegue is using a lot of nuget package references which were previously defined in the "packages.config" file. This file does not exist any more ... instead all nuget references are now included in the csproj file using "<PackageReference Include=...".
When I start my console application it, I'll get the message "(...) error CS0234: The type or namespace name "CodeAnalysis" does not exist in the namespace 'Microsoft' (...)". "Microsoft.CodeAnalysis" is one of the Nuget packages my collegue is using. It seems that the BuildManager does not restore these nuget packages :(
msbuild /version
? Maybe you've got an earlier version of msbuild on your path. – Jon Skeetwhere msbuild
to find out.) – Jon Skeet