From 9186971178e8a093c941621373e01819a31bae7e Mon Sep 17 00:00:00 2001 From: Matthew Grasmick Date: Mon, 24 Apr 2017 13:24:39 -0400 Subject: [PATCH] Fixes #1328: Spaces in project paths break BLT. --- src/Robo/Commands/Blt/DoctorCommand.php | 2 +- template/drush.wrapper | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/Robo/Commands/Blt/DoctorCommand.php b/src/Robo/Commands/Blt/DoctorCommand.php index df639eaee6..30b65eff46 100644 --- a/src/Robo/Commands/Blt/DoctorCommand.php +++ b/src/Robo/Commands/Blt/DoctorCommand.php @@ -79,7 +79,7 @@ protected function executeCommandInDrupalVm($command) { protected function executeDoctorOnHost($alias) { $drush_bin = $this->getConfigValue('composer.bin') . '/drush'; $include_dir = $this->getConfigValue('blt.root') . '/drush'; - $result = $this->taskExec("$drush_bin @$alias --include=$include_dir blt-doctor") + $result = $this->taskExec("'$drush_bin' @$alias --include='$include_dir' blt-doctor") ->dir($this->getConfigValue('docroot')) ->detectInteractive() ->run(); diff --git a/template/drush.wrapper b/template/drush.wrapper index ad3f1153ec..cc52391a69 100755 --- a/template/drush.wrapper +++ b/template/drush.wrapper @@ -28,13 +28,13 @@ # `../vendor/bin/drush.launcher --local $@` is a common variant for # composer-managed Drupal sites. # -DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd ) +DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" cd "`dirname $0`" -if [ ! -f ${DIR}/vendor/drush/drush/drush.launcher ]; then +if [ ! -f "${DIR}/vendor/drush/drush/drush.launcher" ]; then echo >&2 "Drush was not found in this project's vendor directory. You can install it by typing:" echo >&2 "composer install" exit 1 fi -vendor/drush/drush/drush.launcher --config=${DIR}/drush/drushrc.php --alias-path=${DIR}/drush/site-aliases "$@" +vendor/drush/drush/drush.launcher --config="${DIR}/drush/drushrc.php" --alias-path="${DIR}/drush/site-aliases" "$@"