Manual / tail
tail(1)
| TAIL(1) | General Commands Manual | TAIL(1) |
NAME
tail - deliver the last part of a file
SYNOPSIS
tail [-f] [-n number|-number|-c number] [file]
DESCRIPTION
Tail copies the last part of the named file to the standard output. If no file is named, the standard input is used. The default is the last ten lines.
- -n number
- Copy the last number lines. The spelling -number is also accepted.
- -c number
- Copy the last number bytes.
- -f
- After copying, do not stop: look at the file once a second and copy whatever has been appended, until interrupted (a typed ^C ends it, status 130). The file is reopened on every look, because a ProDOS file's end-of-file is not shared between two openers; a file that has become shorter is followed from its start. Needs a timer (a mouse card or a Mockingboard) and refuses without one, like sleep(1). Ignored when reading the standard input.
A final unterminated line is counted as a line.
FILES
/usr/man/TAIL this page
SEE ALSO
DIAGNOSTICS
Exit status is 0 on success, 1 if the input cannot be opened, 2 for usage or range errors.
BUGS
Tails relative to the end of the file are treasured up in a buffer, and thus are limited in length. Here the limits are 64 lines, 255 bytes per stored line, and 255 bytes for -c. There is no +number start-relative form. With -f the wait between looks is a polling loop, so it holds the processor as sleep(1) does.
| October 8, 2026 | maux |