How to display non-printing characters?

0415

To display non-printing characters in a file using the cat command, you can use the -v option. This option will show non-printing characters (except for line feed and tab) in a visible format.

For example, you can run the following command:

cat -v filename.txt

This will display the contents of filename.txt, with non-printing characters represented in a way that makes them visible, such as using ^ for control characters.

If you want to see all non-printing characters, including tabs and line feeds, you can combine the -A option, which is equivalent to -vET:

cat -A filename.txt

This will show all non-printing characters, end-of-line characters, and tabs in a visible format.

0 Comments

no data
Be the first to share your comment!