2017-02-25 118 views
2

我跑在構建腳本MSBuild的,我得到這個錯誤:的MSBuild日誌文件的位置

MSBUILD : error MSB4166: Child node "2" exited prematurely. Shutting down. Diagnostic information may be found in files in the temporary files directory named MSBuild_*.failure.txt. 

我無法找到該文件的MSBuild _ * failure.txt我的機器上。是否需要配置?如果不是,該文件的默認位置是什麼?

+2

嘗試過'%temp%'?這應該讓你到默認的臨時目錄... – jessehouwing

+0

@jessehouwing問題是,如果msbuild在CI服務器下運行,它的概率是比操作系統上的diff用戶比交互式用戶,所以msbuild輸出需要指定DIR .... – Jonesome

回答

0

您可以運行

msbuild /v:diag > c:\log.txt

強迫你的日誌文件中去c:\log.txt。可以使用/flp:filename=c:\log.txt,更多信息here