【问题标题】:MSBuild log file locationMSBuild 日志文件位置
【发布时间】:2017-02-25 15:55:17
【问题描述】:

我在构建脚本中运行 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。它是需要配置的东西吗?如果不是,该文件的默认位置是什么?

【问题讨论】:

  • 试过%temp%?这应该会让你进入默认的临时目录......
  • @jessehouwing 问题是,如果 msbuild 在 CI 服务器下运行,它可能是操作系统上的差异用户而不是您的交互式用户,因此 msbuild 输出需要指定目录....

标签: c# msbuild


【解决方案1】:

你可以跑

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

强制您的日志文件转到c:\log.txt

或者,您可以使用/flp:filename=c:\log.txt,更多信息here

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2018-06-04
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2012-07-16
    • 2019-10-29
    • 2019-04-10
    • 2019-07-28
    相关资源
    最近更新 更多