protected function runTask($container, $task)
    {
        $macroOptions = $container->getMacroOptions($this->argument('task'));

        $confirm = $container->getTask($task, $macroOptions)->confirm;

        if ($confirm && ! $this->confirmTaskWithUser($task, $confirm)) {
            return;
        }

        if (($exitCode = $this->runTaskOverSSH($container->getTask($task, $macroOptions))) > 0) {
            foreach ($container->getErrorCallbacks() as $callback) {
                call_user_func($callback, $task);
            }

            return $exitCode;
        }

        foreach ($container->getAfterCallbacks() as $callback) {
            call_user_func($callback, $task);
        }
    }
protected function runTask($container, $task)
    {
        $macroOptions = $container->getMacroOptions($this->argument('task'));

        $confirm = $container->getTask($task, $macroOptions)->confirm;

        if ($confirm && ! $this->confirmTaskWithUser($task, $confirm)) {
            return;
        }

        if (($exitCode = $this->runTaskOverSSH($container->getTask($task, $macroOptions))) > 0) {
            foreach ($container->getErrorCallbacks() as $callback) {
                call_user_func($callback, $task);
            }

            return $exitCode;
        }

        foreach ($container->getAfterCallbacks() as $callback) {
            call_user_func($callback, $task);
        }
    }
protected function runTask ( $ container , $ task ) { $ macroOptions = $ container -> getMacroOptions ( $ this -> argument ( 'task' ) ) ; $ confirm = $ container -> getTask ( $ task , $ macroOptions ) -> confirm ; if ( $ confirm && ! $ this -> confirmTaskWithUser ( $ task , $ confirm ) ) { return ; } if ( ( $ exitCode = $ this -> runTaskOverSSH ( $ container -> getTask ( $ task , $ macroOptions ) ) ) > 0 ) { foreach ( $ container -> getErrorCallbacks ( ) as $ callback ) { call_user_func ( $ callback , $ task ) ; } return $ exitCode ; } foreach ( $ container -> getAfterCallbacks ( ) as $ callback ) { call_user_func ( $ callback , $ task ) ; } }
Run the given task out of the container.

@param  \Laravel\Envoy\TaskContainer  $container
@param  string  $task
@return null|int|void
Run the given task out of the container .