Manual Page Result
0
Command: tail | Section: 1 | Source: UNIX v10 | File: tail.1
TAIL(1) General Commands Manual TAIL(1)
NAME
tail, readslow, head - print the last part of a file
SYNOPSIS
tail [ otion ... +-number[lbc][rf] ] [ file ]
DESCRIPTION
Tail copies the named file to the standard output beginning at a desig-
nated place, normally 10 lines from the end. If no file is named, the
standard input is used. The options are
+-number[lbc][rf]
Copying begins at position +number measured from the beginning,
or -number from the end of the input. Number is counted in
lines, 1K blocks or characters, according to the appended flag
(default), or Further flags and have the effect of options -r
and -l .
-r Print lines from the end of the file in reverse order. Default
line count is unbounded.
-f Follow. After printing to the end, keep watch and print further
data as it appears.
-c +-number
-n +-number
Number may be signed, with sign - assumed by default. The ef-
fect is the same as +-numberc or +-numberl [sic] respectively.
EXAMPLES
tail file
Print the last 10 lines of a file.
tail +0f file
Print a file, and continue to watch data accumulate as it grows.
A similar function is sometimes called readslow.
sed 10q file
Print the first 10 lines of a file. A similar function is some-
times called head.
SEE ALSO
dd(1)
BUGS
Tails relative to the end of the file are treasured up in a buffer, and
thus are limited in length, even under option -r.
According to custom, option +number counts lines from 1, and counts
blocks and characters from 0.
TAIL(1)