From 32a1a07b22b0af2cf83a2151ece7439630106c99 Mon Sep 17 00:00:00 2001 From: Balint Kleri Date: Sat, 28 Jul 2018 00:19:45 +0200 Subject: [PATCH] =?UTF-8?q?Adjust=20Composer=20script=20name:=20robo=20?= =?UTF-8?q?=E2=86=92=20spark?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The new readme includes adding a Composer script with the name ‘spark’. When Spark was originally written this name was ‘robo’, and that’s how our tasks which we use to execute others referred to it. This breaks things if a Sparkfied project is set up according to the new readme, which makes more sense, so let’s adjust how we invoke the Composer script. --- src/Robo/Tasks.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Robo/Tasks.php b/src/Robo/Tasks.php index 5920001..d920da7 100644 --- a/src/Robo/Tasks.php +++ b/src/Robo/Tasks.php @@ -93,14 +93,14 @@ protected function taskSparkExec($command, $args = []) { foreach ($args as &$arg) { $arg = sprintf('"%s"', $arg); } - $this->taskExec(sprintf('composer run -d %s robo %s %s', $this->workDir, $command, implode(' ', $args)))->run(); + $this->taskExec(sprintf('composer run -d %s spark %s %s', $this->workDir, $command, implode(' ', $args)))->run(); } protected function taskSparkContainerExec($container, $command) { if (is_array($command)) { $command = implode('; ', $command); } - $cmd_tpl = 'composer run -d %s robo containers:exec \'%s\' \'/bin/sh -c "%s"\''; + $cmd_tpl = 'composer run -d %s spark containers:exec \'%s\' \'/bin/sh -c "%s"\''; $this->taskExec(sprintf($cmd_tpl, $this->workDir, $container, $command))->run(); }