Skip to content

Commit 593d6e5

Browse files
committed
fix(biomejs): enable TTY only if supported
1 parent 05af236 commit 593d6e5

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

config/services.php

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,15 @@
55
use Kocal\BiomeJsBundle\Command\BiomeJsCheckCommand;
66
use Kocal\BiomeJsBundle\Command\BiomeJsCiCommand;
77
use Symfony\Component\DependencyInjection\Loader\Configurator\ContainerConfigurator;
8+
use Symfony\Component\Process\Process;
89
use function Symfony\Component\DependencyInjection\Loader\Configurator\abstract_arg;
910
use function Symfony\Component\DependencyInjection\Loader\Configurator\param;
1011
use function Symfony\Component\DependencyInjection\Loader\Configurator\service;
1112

1213
return static function (ContainerConfigurator $container): void {
1314
$container->parameters()
1415
// Internal parameter to enable/disable TTY mode, useful for tests (if someone has a better idea, feel free to suggest it!)
15-
->set('biomejs.use_tty', true)
16+
->set('biomejs.use_tty', Process::isTtySupported())
1617
;
1718

1819
$container->services()
@@ -40,4 +41,4 @@
4041
service('biomejs'),
4142
])
4243
->tag('console.command');
43-
};
44+
};

0 commit comments

Comments
 (0)