All rights reserved. The Berkeley software License Agreement
specifies the terms and conditions for redistribution.
@(#)cat.1 4.1 (Berkeley) 04/29/85
cat file
prints the file, and
cat file1 file2 >file3
concatenates the first two files and places the result on the third.
If no input file is given, or if the argument `-' is encountered, cat reads from the standard input file. Output is buffered in 1024-byte blocks unless the standard output is a terminal, in which case it is line buffered. The -u option causes the output to be completely unbuffered.
The option -n causes the output lines to be numbered sequentially from 1. Giving -b with -n causes numbers to be omitted from blank lines.
The option -s causes the output to be single spaced by crushing out multiple adjacent empty lines.
The option -v causes non-printing characters to be printed in a visible way. Control characters print like ^X for control-x; the delete character (octal 0177) prints as ^?. Non-ascii characters (with the high bit set) are printed as M- (for meta) followed by the character of the low 7 bits. A -e option may be given with -v and causes the ends of lines to be followed by the character `$'; the -t option with -v causes tabs to be printed as ^I.