我正在使用构建工具 2017 在 TFS2017 Update 3 上构建 Web 服务项目。我收到以下错误
C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\15.0\Bin\Microsoft.CSharp.CurrentVersion.targets(322,5): Error MSB4019: The imported project "C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\15.0\Bin\Roslyn\Microsoft.CSharp.Core.targets" was not found. Confirm that the path in the declaration is correct, and that the file exists on disk.
我需要采取哪些步骤来修复此错误?
最佳答案
就我而言,打开现有的解决方案文件(扩展名为.sln
),它安装了所有缺少的依赖项。
否则检查 nuget.org 是否缺少目标包手动安装它们(例如 MSBuild.Microsoft.VisualStudio.Web.targets
)。
关于c# - Microsoft.CSharp.Core.targets 缺失,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/47260114/