diff --git a/PHPCI/Helper/BaseCommandExecutor.php b/PHPCI/Helper/BaseCommandExecutor.php index 1b1d757f..8084cfe3 100644 --- a/PHPCI/Helper/BaseCommandExecutor.php +++ b/PHPCI/Helper/BaseCommandExecutor.php @@ -102,7 +102,6 @@ abstract class BaseCommandExecutor implements CommandExecutor } $this->lastOutput = explode(PHP_EOL, $this->lastOutput); - $this->lastError = "\033[0;31m" . $this->lastError . "\033[0m"; $shouldOutput = ($this->logExecOutput && ($this->verbose || $status != 0)); @@ -111,8 +110,8 @@ abstract class BaseCommandExecutor implements CommandExecutor } if (!empty($this->lastError)) { - $this->logger->log('Error trying to execute: ' . $command); - $this->logger->log($this->lastError, LogLevel::ERROR); + $this->logger->log("\033[0;31m" . 'Error trying to execute: ' . $command . "\033[0m", LogLevel::ERROR); + $this->logger->log("\033[0;31m" . $this->lastError . "\033[0m", LogLevel::ERROR); } $rtn = false;