Skip to content

Commit

Permalink
Merge pull request #34 from Robindfuller/patch-1
Browse files Browse the repository at this point in the history
Escapes spaces in command filename
  • Loading branch information
mikehaertl authored Jul 7, 2018
2 parents 7129dce + b398d64 commit 35648b3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Command.php
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ public function setCommand($command)

// Absolute path. If it's a relative path, let it slide.
if ($position) {
$command = sprintf($command[$position - 1].': && cd %s && %s', escapeshellarg(dirname($command)), basename($command));
$command = sprintf($command[$position - 1].': && cd %s && %s', escapeshellarg(dirname($command)), escapeshellarg(basename($command)));
}
}
$this->_command = $command;
Expand Down

0 comments on commit 35648b3

Please sign in to comment.