You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@karaf.apache.org by "Claus Ibsen (JIRA)" <ji...@apache.org> on 2013/07/22 10:50:48 UTC
[jira] [Created] (KARAF-2401) Command to show and edit shell colors
Claus Ibsen created KARAF-2401:
----------------------------------
Summary: Command to show and edit shell colors
Key: KARAF-2401
URL: https://issues.apache.org/jira/browse/KARAF-2401
Project: Karaf
Issue Type: New Feature
Components: karaf-shell
Reporter: Claus Ibsen
Apache Karaf uses colors in the shell. For example red for ERROR lines in the logs, and so forth.
The end user can change these colors in the configuration file, but this is not easy to do for the average end user.
It would be great if Karaf offers
- a command to show the current color settings (with example)
- a command to change color
Also down the road it would be great if we could have color themes. So people can easily switch to another scheme. For example a black/white. And also create their own color themes.
The default colors is not ideal. For example Windows users has horrible experience as the red and blue colors is very hard to read on a standard windows DOS prompt.
There is some way to change the colors in the DOS prompt but Windows people dont know about this. And frankly it would be nicer if Karaf offered a better out of the box experience.
Some links about changing colors
http://tmielke.blogspot.de/2013/04/how-to-chang-colors-in-karaf-shell.html
Alternatively, you can edit the etc/org.apache.karaf.shell.log.cfg file and add the following properties
fatalColor=39
errorColor=39
warnColor=39
infoColor=39
debugColor=39
traceColor=39
See http://en.wikipedia.org/wiki/ANSI_escape_code for standard colours.
The string is prepended with 0x27 and '[' and suffixed by 'm to build a correct ansi code, so it should be possible to build more complicated colour strings for blinkings and such.
For example the following setting
infoColor=1m\0x2739
will turn on bold with default colour for info statements.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira