What is the simplest way to enable ANSI escape codes (eg. colored output) in Windows cmd?
Asked
Active
Viewed 1.2k times
5
-
See my edited answer. – Dennis Williamson Jan 25 '10 at 16:18
2 Answers
5
CMD
does not support ANSI escape sequences. You'll have to use COMMAND.COM
. What is it that you're trying to do?
How to Enable ANSI.SYS in a Command Window (for COMMAND.COM)
How to Use ANSI.SYS in Windows NT (for COMMAND.COM)
Edit:
You can get less
for Windows and use:
less -R filename

Dennis Williamson
- 62,149
- 16
- 116
- 151
-
I'm trying to view Rails log files that use ANSI codes for colored output – Jakub Arnold Jan 25 '10 at 15:29
2
You might try Cygwin's bash. Terminal colorization is something that Just Works under Cygwin.

Gerald Combs
- 6,441
- 25
- 35