When using "nuget pack MyProject.csproj -Properties Configuration=Release", the release dll is picked up successfully. However, when using "nuget pack MyProject.csproj -Build -Properties Configuration=Release", then the dll gets built and packed in its default configuration (which, in that case, is Debug).<br /><br />I made a reproduction for that bug in a zip file - you would just have to run the NugetPackBuildRelease.bat file in order to reproduce the bug. I believe that the underlying issue is the one in the title of that ticket - that none of the properties specified in nuget pack are passed to MSBuild.<br /><br />This bug is annoying because it means that the "-Build" switch is ultimately suited only to the simplest build processes, which do not use any properties - any more evolved use case would require direct use of MSBuild.
↧