We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e5bd504 commit 0c03385Copy full SHA for 0c03385
packages/console/src/Terminal/Terminal.php
@@ -15,8 +15,6 @@
15
use function function_exists;
16
use function Tempest\Support\arr;
17
18
-use const DIRECTORY_SEPARATOR;
19
-
20
final class Terminal
21
{
22
public int $width;
@@ -151,11 +149,11 @@ public function disableTty(): self
151
149
152
150
public static function supportsTty(): bool
153
154
- if (! function_exists('shell_exec')) {
+ if (PHP_OS_FAMILY === 'Windows' || ! function_exists('shell_exec')) {
155
return false;
156
}
157
158
- return (bool) shell_exec('stty 2> ' . ('\\' === DIRECTORY_SEPARATOR ? 'NUL' : '/dev/null'));
+ return (bool) shell_exec('stty 2> /dev/null');
159
160
161
private function clear(): self
0 commit comments