Skip to content

Commit

Permalink
Fix issue when environment command ends with new line.
Browse files Browse the repository at this point in the history
  • Loading branch information
fago committed Apr 20, 2018
1 parent b99cd74 commit 3373cd7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Task/Exec.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ protected function ensureValidPhappEnvironment() {
// command.
$command = ' [ ! -z "$PHAPP_ENV" ]';
if ($env_command = $this->manifest->getCommand('environment')) {
$command = $env_command . $command ;
$command = trim($env_command) . ' ' . $command ;
}
$process = new Process($this->ensureCommandRunsViaBash($command));
if ($this->workingDirectory) {
Expand Down Expand Up @@ -80,7 +80,7 @@ public function getCommand($run_via_bash = TRUE) {
$this->ensureValidPhappEnvironment();

if ($env_command = $this->manifest->getCommand('environment')) {
$command = $env_command . " && " . $command;
$command = trim($env_command) . " && " . $command;
}
}

Expand Down

0 comments on commit 3373cd7

Please sign in to comment.