【发布时间】:2019-12-04 23:15:25
【问题描述】:
我正在尝试使用以下命令构建 dotnet 解决方案,但出现错误
CS0234: The type or namespace name 'VisualStudio' does not exist in the namespace 'Microsoft' using MSBuild.exe
命令:
bat "\"${tool 'MSBuild'}\" Test.sln /t:Rebuild /p:Configuration=Release /p:VisualStudioVersion=14.0 /p:NoWarn=7035 /p:Platform=\"Any CPU\" "
代码存在于 Bitbucket 中,我正在从 Jenkins 触发构建。代码在windows server中运行。
bat "\"${tool 'MSBuild'}\" Test.sln /t:Rebuild /p:Configuration=Release /p:VisualStudioVersion=14.0 /p:NoWarn=7035 /p:Platform=\"Any CPU\" "
error CS0234: The type or namespace name 'VisualStudio' does not exist in the namespace 'Microsoft' (are you missing an assembly reference?)
error CS0246: The type or namespace name 'TestClass' could not be found (are you missing a using directive or an assembly reference?)
error CS0246: The type or namespace name 'TestInitialize' could not be found (are you missing a using directive or an assembly reference?)
error CS0246: The type or namespace name 'TestMethod' could not be found (are you missing a using directive or an assembly reference?)
【问题讨论】:
标签: jenkins-groovy msbuild-4.0