[Console] Console colorization is also provided by ConEmu on Windows
This commit is contained in:
parent
885d473366
commit
bb2566c17d
@ -1,6 +1,11 @@
|
||||
CHANGELOG
|
||||
=========
|
||||
|
||||
2.1.2
|
||||
-----
|
||||
|
||||
* added support for colorization on Windows via ConEmu
|
||||
|
||||
2.1.0
|
||||
-----
|
||||
|
||||
|
@ -95,7 +95,7 @@ class StreamOutput extends Output
|
||||
*
|
||||
* Colorization is disabled if not supported by the stream:
|
||||
*
|
||||
* - windows without ansicon
|
||||
* - windows without ansicon and ConEmu
|
||||
* - non tty consoles
|
||||
*
|
||||
* @return Boolean true if the stream supports colorization, false otherwise
|
||||
@ -104,7 +104,7 @@ class StreamOutput extends Output
|
||||
{
|
||||
// @codeCoverageIgnoreStart
|
||||
if (DIRECTORY_SEPARATOR == '\\') {
|
||||
return false !== getenv('ANSICON');
|
||||
return false !== getenv('ANSICON') || 'ON' === getenv('ConEmuANSI');
|
||||
}
|
||||
|
||||
return function_exists('posix_isatty') && @posix_isatty($this->stream);
|
||||
|
Reference in New Issue
Block a user