Description
Description
On Konsole and Yakuake the visualization of <href>
tag is broken, and the output is shown enclosed by backslashes.
On PhpStorm terminal the output "crashes": at the first escape sequence the terminal stops printing the text, but the execution terminates smoothly.
On the same machine (Kubuntu Disco Dingo) XTerm and system console work well, ignoring the unrecognized escape sequences.
How to reproduce
Just run a command who outputs links. For me it was a simple bin/console debug:router
in a Symfony Framework project, as I integrated the source linking to PhpStorm.
Possible Solution
I've debugged all the way and found that the check for unsupported terminal emulators is on line 189 of Formatter/OutputFormatterStile.php
:
if (null === $this->handlesHrefGracefully) {
$this->handlesHrefGracefully = 'JetBrains-JediTerm' !== getenv('TERMINAL_EMULATOR');
}
I understand thas is the correct point to work on, but I really don't know anything about terminal emulators. If someone points me in the correct direction I can create a pull request.
Additional context
The output on PhpStorm terminal:
The output on a Yakuake terminal (same engine of Konsole); cut because long output: