簡體   English   中英

Visual Studio工作時,MSBuild無法生成解決方案

[英]MSBuild cannot build a solution when Visual Studio works

我試圖在我的小github存儲庫中添加CI支持,因此我將其配置為使用appveyor 但是它無法構建我的解決方案,並因奇數錯誤而失敗。 但是它有一個構建日志,因此我在控制台中重新輸入了它們,並遇到了完全相同的問題, The type or namespace name 'System' could not be foundThe type or namespace name 'System' could not be found多個奇數錯誤

git clone -q --branch=master https://github.com/Pzixel/RemoteClient.git C:\projects\remoteclient
msbuild "C:\projects\remoteclient\RemoteClient\RemoteClient.sln" /verbosity:minimal

在此處輸入圖片說明 同樣在AppVeyor中: https ://ci.appveyor.com/project/Pzixel/remoteclient

但是VS2017很好用: 在此處輸入圖片說明

為什么會發生,如何解決?

我認為,在構建解決方案之前,您需要還原nuget軟件包。 您可以在此處下載nuget.exe

比您可以運行:

nuget restore RemoteClient.sln
msbuild RemoteClient.sln

我做了一個干凈的結帳並運行了兩個命令。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM