/** * Get the command with options and arguments * * @return string */ protected function getCommand() { $cmd = $this->get('command'); $argv = substr(parent::getCommand(), strlen($cmd)) . ' '; if (strpos($argv, ' --no-ansi ') === false && strpos($argv, ' --ansi ') === false && $this->console->getOutput()->isDecorated()) { $argv = ' --ansi' . $argv; } if (!$this->shouldExecute() && strpos($argv, ' --dry-run ') === false) { $argv = ' --dry-run' . $argv; } return $cmd . rtrim($argv); }