diff --git a/src/Builder/API/APIRuntime.php b/src/Builder/API/APIRuntime.php index fc17cd15..84f36637 100644 --- a/src/Builder/API/APIRuntime.php +++ b/src/Builder/API/APIRuntime.php @@ -23,7 +23,7 @@ class: new Node\Name\FullyQualified('Kiboko\\Component\\Pipeline\\PipelineRunner args: [ new Node\Arg( value: new Node\Expr\New_( - class: new Node\Name\FullyQualified('Ps\\Log\\NullLogger') + class: new Node\Name\FullyQualified('Psr\\Log\\NullLogger') ) ), ] diff --git a/src/Cloud/Console/Command/RemoveCommand.php b/src/Cloud/Console/Command/RemoveCommand.php index 3bf52eff..eca126fd 100644 --- a/src/Cloud/Console/Command/RemoveCommand.php +++ b/src/Cloud/Console/Command/RemoveCommand.php @@ -22,6 +22,7 @@ protected function configure(): void $this->addOption('url', 'u', mode: Console\Input\InputArgument::OPTIONAL, description: 'Base URL of the cloud instance', default: 'https://app.gyroscops.com'); $this->addOption('beta', mode: Console\Input\InputOption::VALUE_NONE, description: 'Shortcut to set the cloud instance to https://beta.gyroscops.com'); $this->addOption('ssl', mode: Console\Input\InputOption::VALUE_NEGATABLE, description: 'Enable or disable SSL'); + $this->addOption('output', mode: Console\Input\InputOption::VALUE_OPTIONAL, description: 'Specify the path of the working directory'); $this->addArgument('config', mode: Console\Input\InputArgument::REQUIRED); } @@ -70,7 +71,7 @@ protected function execute(Console\Input\InputInterface $input, Console\Output\O } $context = new Satellite\Console\RuntimeContext( - 'php://fd/3', + $input->getOption('output') ?? 'php://fd/3', new Satellite\ExpressionLanguage\ExpressionLanguage(), ); diff --git a/src/Service.php b/src/Service.php index 9c43c7f6..4dbe781b 100644 --- a/src/Service.php +++ b/src/Service.php @@ -276,7 +276,7 @@ private function compileWorkflow(array $config): Satellite\Builder\Repository\Wo ) ); - foreach ($config['workflow']['jobs'] as $job) { + foreach ($config['workflow']['jobs'] as $code => $job) { if (\array_key_exists('pipeline', $job)) { $pipeline = $this->compilePipelineJob($job); $pipelineFilename = sprintf('%s.php', uniqid('pipeline')); @@ -293,7 +293,7 @@ private function compileWorkflow(array $config): Satellite\Builder\Repository\Wo ) ); - $workflow->addPipeline($job['pipeline']['code'], $pipelineFilename); + $workflow->addPipeline($code, $pipelineFilename); } elseif (\array_key_exists('action', $job)) { $action = $this->compileActionJob($job); $actionFilename = sprintf('%s.php', uniqid('action')); @@ -310,7 +310,7 @@ private function compileWorkflow(array $config): Satellite\Builder\Repository\Wo ) ); - $workflow->addAction($job['action']['code'], $actionFilename); + $workflow->addAction($code, $actionFilename); } else { throw new \LogicException('Not implemented'); }