gpt4 book ai didi

msbuild - 在 MSBuild 任务中引发错误

转载 作者:行者123 更新时间:2023-12-01 23:11:02 25 4
gpt4 key购买 nike

如何从 MSBuild 任务中抛出错误并强制构建失败。像这样的东西:

<Task>
<ThrowError Condition="$(SomeCondition)" Message="There was a problem with the build" />
</Task>

最佳答案

使用Error Task

<Error Condition="$(SomeCondition)" Text="There was a problem with the build" />

关于msbuild - 在 MSBuild 任务中引发错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/2402265/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com