TAIL(1) COMMAND REFERENCE TAIL(1) NAME tail - copy the last part of a file to standard output SYNOPSIS tail [ +[number][lbc][fr] ] [ filename ] DESCRIPTION Tail copies the named file to the standard output beginning at a designated place. If no file is named, the standard input is used. Copying begins at distance +number from the beginning, or -number from the end of the input. Specifying r causes tail to print lines from the end-of-file in reverse order. The default for r is to print the entire file this way. Specifying f causes tail to not quit at end-of-file, but rather wait and try to read repeatedly in hopes that the file will grow. If both r and f are given, the f is ignored. OPTIONS -f Causes tail to not quit at end-of-file, but rather wait and try to read repeatedly in hopes that the file will grow. -r Causes tail to print lines from the end of the file in reverse order. +number Copying begins at distance +number from the beginning of the input. -number Copying begins at distance -number from the end of the input. Number is counted in units of lines, 1024-byte blocks or characters, according to the appended option l, b or c, respectively. When no units are specified, counting is by lines. When the size argument is not specified, the last 10 lines are copied. EXAMPLES The following example reads the output from nroff(1) which is being written to the file text.out. The last 30 lines of output are displayed first, and then all subsequent output is displayed. nroff file > text.out& tail -30lf text.out This example builds a new copy of the file example containing all but the first 29 lines of the original copy. Printed 5/12/88 1
TAIL(1) COMMAND REFERENCE TAIL(1) tail +30 example > tmp mv tmp example RETURN VALUE [NO_ERRS] Command completed without error. [USAGE] Incorrect command line syntax. Execution terminated. [P_ERR] A system error occurred. Execution terminated. See intro(2) for more information on system errors. CAVEATS When the -number or -r options are used, a maximum of 16384 characters can be copied. Various kinds of anomalous behavior may happen with character special files. SEE ALSO dd(1) and head(1). Printed 5/12/88 2
%%index%% na:240,106; sy:346,256; de:602,923; op:1525,991; ex:2516,527;3355,59; rv:3414,444; ca:3858,295; se:4153,149; %%index%%000000000142