Cake: Make possibility to set Process Exit Code

Created on 29 Mar 2018  路  3Comments  路  Source: cake-build/cake

Currently cake process can return exit code 0 or 1 only.
Will useful if I can return custom Process Exit Code from task.
e.g. throw CakeExitCodeException(-1)

Good first issue Help wanted Up-for-grabs

Most helpful comment

This doesn't have to be a new exception btw. We could add a constructor overload to the CakeException to contain an exit code, since it's always used to indicate a problem within Cake (that will lead to an exit if not handled)

All 3 comments

Yip that could be useful, as a workaround you could currently use System.Environment.Exit(-1);

image

This doesn't have to be a new exception btw. We could add a constructor overload to the CakeException to contain an exit code, since it's always used to indicate a problem within Cake (that will lead to an exit if not handled)

@patriksvensson exactly just an overload constructor with 1 as default.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

vktr picture vktr  路  6Comments

augustoproiete picture augustoproiete  路  5Comments

johncrim picture johncrim  路  4Comments

islopma picture islopma  路  3Comments

gabrielweyer picture gabrielweyer  路  3Comments