A reminder for myself:
ANSI escape characters don’t work properly in Windows terminals:
To make them work properly, use AnsiCon. Unzip it somewhere permanent (eg.
%ProgramFiles%\ansicon) and install it with:
start a new terminal, and lo:
Fine tune the appearance of the programs generating the color, for example customise ‘hg diff’ by editing ~/.hgrc:
[extensions] color = [color] status.modified = yellow bold status.unknown = white status.deleted = red_background white bold diff.deleted = red bold diff.inserted = green bold diff.file_a = white diff.file_b = white diff.diffline = white_background black diff.extended = yellow bold diff.hunk = underline black diff.changed = yellow bold
ANSI is correctly stripped out if the output of a program is not a terminal, so the colored output won’t interfere with saving to files nor machine-parsing of the text: