Skip to content

Commit 0c0e79b

Browse files
committed
Keep the same output if the spinner is not available.
1 parent 6c95401 commit 0c0e79b

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

src/NewCommand.php

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -874,7 +874,7 @@ protected function runCommands($commands, InputInterface $input, OutputInterface
874874
}, $commands);
875875
}
876876

877-
if (! $output->isVerbose()) {
877+
if (! $output->isVerbose() && $this->canUseSpinner($input, $output)) {
878878
$commands = array_map(function ($value) {
879879
if (str_starts_with($value, 'chmod')) {
880880
return $value;
@@ -930,7 +930,11 @@ protected function runCommand(string $command, InputInterface $input, OutputInte
930930
}
931931
}
932932

933-
return tap($process)->run();
933+
$process->run(function ($type, $line) use ($output) {
934+
$output->write(' '.$line);
935+
});
936+
937+
return $process;
934938
}
935939

936940
/**

0 commit comments

Comments
 (0)