Lots of man pages.
This commit is contained in:
parent
08df2a433e
commit
cfa37a7b11
152 changed files with 25407 additions and 148 deletions
86
man/man1/cat.1
Normal file
86
man/man1/cat.1
Normal file
|
|
@ -0,0 +1,86 @@
|
|||
.TH CAT 1
|
||||
.SH NAME
|
||||
cat, read \- catenate files
|
||||
.SH SYNOPSIS
|
||||
.B cat
|
||||
[
|
||||
.I file ...
|
||||
]
|
||||
.br
|
||||
.B read
|
||||
[
|
||||
.B -m
|
||||
] [
|
||||
.B -n
|
||||
.I nline
|
||||
] [
|
||||
.I file ...
|
||||
]
|
||||
.SH DESCRIPTION
|
||||
.I Cat
|
||||
reads each
|
||||
.I file
|
||||
in sequence and writes it on the standard output.
|
||||
Thus
|
||||
.IP
|
||||
.L
|
||||
cat file
|
||||
.LP
|
||||
prints a file and
|
||||
.IP
|
||||
.L
|
||||
cat file1 file2 >file3
|
||||
.LP
|
||||
concatenates the first two files and places the result
|
||||
on the third.
|
||||
.PP
|
||||
If no
|
||||
.I file
|
||||
is given,
|
||||
.I cat
|
||||
reads from the standard input.
|
||||
Output is buffered in blocks matching the input.
|
||||
.PP
|
||||
.I Read
|
||||
copies to standard output exactly one line from the named
|
||||
.IR file ,
|
||||
default standard input.
|
||||
It is useful in interactive
|
||||
.IR rc (1)
|
||||
scripts.
|
||||
.PP
|
||||
The
|
||||
.B -m
|
||||
flag causes it to continue reading and writing multiple lines until end of file;
|
||||
.B -n
|
||||
causes it to read no more than
|
||||
.I nline
|
||||
lines.
|
||||
.PP
|
||||
Read always executes a single
|
||||
.B write
|
||||
for each line of input, which can be helpful when
|
||||
preparing input to programs that expect line-at-a-time data.
|
||||
It never reads any more data from the input than it prints to the output.
|
||||
.SH SOURCE
|
||||
.B /sys/src/cmd/cat.c
|
||||
.br
|
||||
.B /sys/src/cmd/read.c
|
||||
.SH SEE ALSO
|
||||
.IR cp (1)
|
||||
.SH DIAGNOSTICS
|
||||
.I Read
|
||||
exits with status
|
||||
.B eof
|
||||
on end of file or, in the
|
||||
.B -n
|
||||
case, if it doesn't read
|
||||
.I nlines
|
||||
lines.
|
||||
.SH BUGS
|
||||
Beware of
|
||||
.L "cat a b >a"
|
||||
and
|
||||
.LR "cat a b >b" ,
|
||||
which
|
||||
destroy input files before reading them.
|
||||
Loading…
Add table
Add a link
Reference in a new issue