We're updating the issue view to help you get more done. 

We need to review exit codes in Tasks


Exit codes are swallowed up. Ex:

1 2 3 4 5 6 7 function run() { runCommand( 'assertTrue false' ); print.line( 'Finished with success!' ); }

Should the task immediately stop execution when the assertTrue command returns a "failing" exit code of 1? If so, the runCommand method, Command DSL and Task DSL should probably be reworked to actually throw exceptions on a failing status code. That's the only way to have a command automatically fail a task without adding extra plumbing in to capture the exit code and check it every time.

This bring up other questions such as how do we allow someone to PURPOSEFULLY ignore failing command and just keep executing. Try/catch would be one option. Should there be other ways to do it. Look at bash scripts to see how they handle failing commands.



Brad Wood


Gavin Pickin



Fix versions