Museum

Home

Lab Overview

Retrotechnology Articles

⇒ Online Manual

Media Vault

Software Library

Restoration Projects

Artifacts Sought

TAIL(1)

NAME

tail − deliver the last part of a file

SYNOPSIS

tail [ [+-]number[lbc][rf] ] [ file ]

tail [ -fr ] [ -n nlines ] [ -c ncharacters ] [ file ]

DESCRIPTION

Tail copies the named file to the standard output beginning at a designated place.  If no file is named, the standard input is copied. 

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 or Default is -10l (ten ell). 

The further flag causes tail to print lines from the end of the file in reverse order; (follow) causes tail, after printing to the end, to keep watch and print further data as it appears. 

The second syntax is that promulgated by POSIX, where the numbers of lines (-n) or characters (-c) are specified separately as signed integers. Note than an unsigned value is treated as negative, ie ’-n 2’ is equivalent to ’-n -2’. 

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.
According to custom, option +number counts lines from 1, and counts blocks and characters from 0. 

tail -nlines +3 file
Print a file starting at line number 3

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026