|
9 | 9 | use Symfony\Component\Console\Input\InputArgument;
|
10 | 10 | use Symfony\Component\Console\Input\InputInterface;
|
11 | 11 | use Symfony\Component\Console\Input\InputOption;
|
| 12 | +use Symfony\Component\Console\Output\ConsoleOutputInterface; |
12 | 13 | use Symfony\Component\Console\Output\OutputInterface;
|
13 | 14 | use Symfony\Component\Process\Process;
|
14 | 15 |
|
@@ -262,14 +263,17 @@ protected function execute(InputInterface $input, OutputInterface $output): int
|
262 | 263 |
|
263 | 264 | $output->writeln('<comment>Return PHPStan exit code</comment>', OutputInterface::VERBOSITY_DEBUG);
|
264 | 265 |
|
265 |
| - $output->writeln('Thanks for using <info>drupal-check</info>!'); |
266 |
| - $output->writeln(''); |
267 |
| - $output->writeln('Consider sponsoring the development of the maintainers which make <options=bold>drupal-check</> possible:'); |
268 |
| - $output->writeln(''); |
269 |
| - $output->writeln('- <options=bold>phpstan (ondrejmirtes)</>: https://github.com/sponsors/ondrejmirtes'); |
270 |
| - $output->writeln('- <options=bold>phpstan-deprecation-rules (ondrejmirtes))</>: https://github.com/sponsors/ondrejmirtes'); |
271 |
| - $output->writeln('- <options=bold>phpstan-drupal (mglaman))</>: https://github.com/sponsors/mglaman'); |
272 |
| - $output->writeln('- <options=bold>drupal-check (mglaman))</>: https://github.com/sponsors/mglaman'); |
| 266 | + if ($output instanceof ConsoleOutputInterface) { |
| 267 | + $stderr = $output->getErrorOutput(); |
| 268 | + $stderr->writeln('Thanks for using <info>drupal-check</info>!'); |
| 269 | + $stderr->writeln(''); |
| 270 | + $stderr->writeln('Consider sponsoring the development of the maintainers which make <options=bold>drupal-check</> possible:'); |
| 271 | + $stderr->writeln(''); |
| 272 | + $stderr->writeln('- <options=bold>phpstan (ondrejmirtes)</>: https://github.com/sponsors/ondrejmirtes'); |
| 273 | + $stderr->writeln('- <options=bold>phpstan-deprecation-rules (ondrejmirtes))</>: https://github.com/sponsors/ondrejmirtes'); |
| 274 | + $stderr->writeln('- <options=bold>phpstan-drupal (mglaman))</>: https://github.com/sponsors/mglaman'); |
| 275 | + $stderr->writeln('- <options=bold>drupal-check (mglaman))</>: https://github.com/sponsors/mglaman'); |
| 276 | + } |
273 | 277 |
|
274 | 278 | return $process->getExitCode();
|
275 | 279 | }
|
|
0 commit comments