cat
Format:
Cat options files
Option:
-v | to display control characters. |
Cat is the most used file pager for text files.
$ cat myfile
Display the file myfile
$ cat myfile myfile2 >>hold_file
The above will combine two files (myfile and myfile2) into one file called hold_file.
cat dt1 | while read line
do
echo $line
done
Cat is also used to read files in your scripts.
Get Linux and Unix Shell Programming now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.