would be better if you could write:
class CustomCmdCommand extends CConsoleCommand {
public function run( $args ) {
return 112;
}
}
and this should pass returned int as process return code (as in php exit(112) command) so you could check it in system shell:
yiic customCmd
if [ $? == 112 ]; then
FAILED WITH 112 CODE...
fi
now you have to do hacks and call php exit(112) directly which kills all application callstack and can lead to some problems if application stack is not closed properly. It is not very pretty either