Tuesday, September 13, 2011

Show non-printable characters in VI

You just KNOW there's a stray tab or other character in this file, right? So how can you display these characters in vi?

[ESC] to get into command mode
:set list

Look through the file. Tabs will be ^I, DOS-style end-of-lines will be ^M, etc.

To go back:
[ESC] to get into command mode
:set nolist

No comments:

Post a Comment