Archive

Archive for November, 2010

CygWin terminal colors

November 14th, 2010 No comments

Many of the default ANSI colors used by the CygWin terminal are almost unreadable. For example, the blue that is used for directories in a file listing is pretty dark and hard to read on a black background. This limits the color palette that can be used in things such as the PS1 shell prompt. Try the following script (colortable16.sh) to see what your colors currently look like.

The colors can be changed by clicking on the system menu in the upper-left corner and selecting “Properties”. I decided to use the same colors as the Gnome terminal.

This is how the colors are defined in CygWin by default:

Color R G B
Black 0 0 0
Blue 0 0 128
Green 0 128 0
Cyan 0 128 128
Red 128 0 0
Pruple 128 0 128
Brown 128 128 0
Light Gray 192 192 192
Dark Gray 128 128 128
Light Blue 0 0 255
Light Green 0 255 0
Light Cyan 0 255 255
Light Red 255 0 0
Light Purple 255 0 255
Light Yellow 255 255 0
White 255 255 255

This is how they should be changed so that they’re more usable:

Color R G B
Black 0 0 0
Blue 0 0 170
Green 0 170 0
Cyan 0 170 170
Red 170 0 0
Pruple 170 0 170
Brown 170 85 0
Light Gray 170 170 170
Dark Gray 85 85 85
Light Blue 85 85 255
Light Green 85 255 85
Light Cyan 85 255 255
Light Red 255 85 85
Light Purple 255 85 255
Light Yellow 255 255 85
White 255 255 255
Categories: Uncategorized Tags: , ,