mirror of
https://github.com/hauke68/Magallanes.git
synced 2026-09-05 17:08:56 +02:00
Proper exit code. Issue #52
This commit is contained in:
@@ -27,6 +27,8 @@ class UpdateCommand extends AbstractCommand
|
||||
*/
|
||||
public function run()
|
||||
{
|
||||
$exitCode = 200;
|
||||
|
||||
$task = Factory::get('scm/update', $this->getConfig());
|
||||
$task->init();
|
||||
|
||||
@@ -35,9 +37,13 @@ class UpdateCommand extends AbstractCommand
|
||||
|
||||
if ($result == true) {
|
||||
Console::output('<green>OK</green>' . PHP_EOL, 0);
|
||||
$exitCode = 0;
|
||||
|
||||
} else {
|
||||
Console::output('<red>FAIL</red>' . PHP_EOL, 0);
|
||||
}
|
||||
|
||||
return $exitCode;
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user