Unix and Linux Discussions Tagged with tail |
|
Thread / Thread Starter |
Last Post |
Replies |
Views |
Forum |
|
|
|
1 |
12,327 |
Homework & Coursework Questions |
|
|
|
9 |
2,793 |
UNIX for Beginners Questions & Answers |
|
|
|
1 |
1,035 |
Shell Programming and Scripting |
|
|
|
1 |
1,682 |
Shell Programming and Scripting |
|
|
|
2 |
2,888 |
Shell Programming and Scripting |
|
|
|
1 |
1,244 |
UNIX for Beginners Questions & Answers |
|
|
|
7 |
1,976 |
Shell Programming and Scripting |
|
|
|
7 |
6,186 |
UNIX for Advanced & Expert Users |
|
|
|
4 |
1,601 |
Shell Programming and Scripting |
|
|
|
5 |
1,683 |
Shell Programming and Scripting |
|
|
|
10 |
3,195 |
Shell Programming and Scripting |
|
|
|
9 |
10,832 |
Shell Programming and Scripting |
|
|
|
1 |
1,721 |
Shell Programming and Scripting |
|
|
|
5 |
1,730 |
Shell Programming and Scripting |
|
|
|
0 |
4,516 |
Shell Programming and Scripting |
|
|
|
3 |
2,379 |
Shell Programming and Scripting |
|
|
|
11 |
7,364 |
Shell Programming and Scripting |
|
|
|
9 |
14,117 |
Shell Programming and Scripting |
|
|
|
1 |
85,518 |
Shell Programming and Scripting |
|
|
|
2 |
2,613 |
UNIX for Dummies Questions & Answers |
|
|
|
2 |
6,955 |
Shell Programming and Scripting |
|
|
|
3 |
3,366 |
Shell Programming and Scripting |
|
|
|
4 |
2,532 |
UNIX for Dummies Questions & Answers |
|
|
|
2 |
1,751 |
UNIX for Dummies Questions & Answers |
|
|
|
8 |
4,232 |
UNIX for Dummies Questions & Answers |
|
|
|
6 |
3,060 |
UNIX for Dummies Questions & Answers |
|
|
|
4 |
12,772 |
Shell Programming and Scripting |
|
|
|
4 |
4,075 |
Shell Programming and Scripting |
|
|
|
3 |
4,296 |
Shell Programming and Scripting |
|
|
|
7 |
4,506 |
Shell Programming and Scripting |
|
|
|
4 |
2,540 |
Shell Programming and Scripting |
|
|
|
4 |
2,278 |
UNIX for Dummies Questions & Answers |
|
|
|
7 |
79,976 |
Solaris |
|
|
|
3 |
2,894 |
UNIX for Dummies Questions & Answers |
|
|
|
6 |
6,097 |
Shell Programming and Scripting |
|
|
|
6 |
10,412 |
Shell Programming and Scripting |
|
|
|
3 |
5,435 |
UNIX for Dummies Questions & Answers |
|
|
|
10 |
6,033 |
Shell Programming and Scripting |
|
|
|
2 |
123,061 |
UNIX for Dummies Questions & Answers |
|
|
|
1 |
12,151 |
UNIX for Dummies Questions & Answers |
TAIL(1) General Commands Manual 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 rather than the options are signed.
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.
sed 10q file
Print the first 10 lines of a file.
SOURCE
/sys/src/cmd/tail.c
BUGS
Tails relative to the end of the file are treasured up in a buffer, and thus are limited in length.
According to custom, option +number counts lines from 1, and counts blocks and characters from 0.
TAIL(1)