Skip to content

Commit

Permalink
fix xterm detection
Browse files Browse the repository at this point in the history
  • Loading branch information
theofidry committed Dec 8, 2023
1 parent 8d06a8a commit 1b59cb0
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions src/Symfony/Component/Console/Output/StreamOutput.php
Original file line number Diff line number Diff line change
Expand Up @@ -64,9 +64,6 @@ public function getStream()
return $this->stream;
}

/**
* {@inheritdoc}
*/
protected function doWrite(string $message, bool $newline)
{
if ($newline) {
Expand Down Expand Up @@ -107,7 +104,7 @@ protected function hasColorSupport()
&& @sapi_windows_vt100_support($this->stream))
|| false !== getenv('ANSICON')
|| 'ON' === getenv('ConEmuANSI')
|| 'xterm' === getenv('TERM');
|| str_starts_with((string) getenv('TERM'), 'xterm');
}

return stream_isatty($this->stream);
Expand Down

0 comments on commit 1b59cb0

Please sign in to comment.