howl-editor / howl

The Howl Editor
http://howl.io
Other
713 stars 68 forks source link

No colors in the process buffer #492

Open dgaw opened 5 years ago

dgaw commented 5 years ago

I've noticed that the build tools that display color in a normal terminal don't display color in Howl's process buffer. I believe ANSI colors are supported so I'm wondering what might be wrong.

Steps to reproduce:

  1. ctrl shift r
  2. ls --color=auto

Expected result:

Actual result:

Interestingly, when I type ls --color=always then the colors do work so I presume it's something to do with ls (and other tools) not recognizing the color capability. I do have TERM=xterm-256color and COLORTERM=truecolor env variables though.

Any ideas?

Edit: I'm on the current master (fdf0997).

rokf commented 5 years ago

Isn't that the default behavior of most command line tools? When they're piped somewhere (not a tty) then they do not output color, except if forced.

dgaw commented 5 years ago

I think you're right @rokf. However, Spacemacs for example manages to work around this and build tools display color in its compilation buffer. I'll have a look at how they do it.

nilnor commented 5 years ago

Yes, Howl manages ANSI color output if present, but most tools don't emit if unless they detect that they're in a terminal, which is why they have to be forced. To get around this you'd have to fake a terminal using a psuedo TTY, which entails some effort.

dgaw commented 5 years ago

Thanks for the answers. I've checked the tools I use and they can all be forced to use color so I'm putting this one on a back burner.

shalabhc commented 4 years ago

This is related to #218 - terminal emulation.