How to enable diagnostic verbosity for Cake

无人久伴 提交于 2019-12-27 12:05:39

问题


I am having some problems running my build.cake file, but I can't immediately see what the problem is. Is there a way to enable diagnostic verbosity, so I can get more information about what is going on, and how to fix the problem?


回答1:


Yes, you can easily enable diagnostic verbosity in Cake. This allows you to see much more information about the Cake execution, including the actual commands, and arguments, that are passed to the numerous underlying tools that Cake can call on your behalf. This can be especially useful if you are finding issues when calling tools, and things aren't working as expected. By getting the command that is being called, you can test this outwith Cake to make sure it is working as expected.

How you enable diagnostic verbosity really depends on how you are calling the cake.exe.

Directly

cake.exe --verbosity=diagnostic

Via PowerShell Bootstrapper

.\build.ps1 -Verbosity Diagnostic

Via Bash Bootstrapper

.\build.sh --verbosity=diagnostic

NOTE: Another option might be to debug your build.cake file. This can be done by passing --debug into cake.exe, and then attaching the debugger. More information on this can be found here.

In addition, you can also pass other options for the Verbosity flag. These are described in detail here. These options are:

  • Minimal
  • Normal
  • Quiet
  • Verbose


来源:https://stackoverflow.com/questions/38658660/how-to-enable-diagnostic-verbosity-for-cake

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!