Blame


1 78e51a8c 2005-01-14 devnull <head>
2 78e51a8c 2005-01-14 devnull <title>tail(1) - Plan 9 from User Space</title>
3 78e51a8c 2005-01-14 devnull <meta content="text/html; charset=utf-8" http-equiv=Content-Type>
4 78e51a8c 2005-01-14 devnull </head>
5 78e51a8c 2005-01-14 devnull <body bgcolor=#ffffff>
6 78e51a8c 2005-01-14 devnull <table border=0 cellpadding=0 cellspacing=0 width=100%>
7 78e51a8c 2005-01-14 devnull <tr height=10><td>
8 78e51a8c 2005-01-14 devnull <tr><td width=20><td>
9 78e51a8c 2005-01-14 devnull <tr><td width=20><td><b>TAIL(1)</b><td align=right><b>TAIL(1)</b>
10 78e51a8c 2005-01-14 devnull <tr><td width=20><td colspan=2>
11 78e51a8c 2005-01-14 devnull <br>
12 78e51a8c 2005-01-14 devnull <p><font size=+1><b>NAME </b></font><br>
13 78e51a8c 2005-01-14 devnull
14 78e51a8c 2005-01-14 devnull <table border=0 cellpadding=0 cellspacing=0><tr height=2><td><tr><td width=20><td>
15 78e51a8c 2005-01-14 devnull
16 78e51a8c 2005-01-14 devnull tail &ndash; deliver the last part of a file<br>
17 78e51a8c 2005-01-14 devnull
18 78e51a8c 2005-01-14 devnull </table>
19 78e51a8c 2005-01-14 devnull <p><font size=+1><b>SYNOPSIS </b></font><br>
20 78e51a8c 2005-01-14 devnull
21 78e51a8c 2005-01-14 devnull <table border=0 cellpadding=0 cellspacing=0><tr height=2><td><tr><td width=20><td>
22 78e51a8c 2005-01-14 devnull
23 78e51a8c 2005-01-14 devnull <tt><font size=+1>tail</font></tt> [ <tt><font size=+1>+&#8722;</font></tt><i>number</i>[<tt><font size=+1>lbc</font></tt>][<tt><font size=+1>rf</font></tt>] ] [ <i>file</i> ]
24 78e51a8c 2005-01-14 devnull <table border=0 cellpadding=0 cellspacing=0><tr height=5><td></table>
25 78e51a8c 2005-01-14 devnull
26 78e51a8c 2005-01-14 devnull <tt><font size=+1>tail</font></tt> [ <tt><font size=+1>&#8722;fr</font></tt> ] [ <tt><font size=+1>&#8722;n</font></tt> <i>nlines</i> ] [ <tt><font size=+1>&#8722;c</font></tt> <i>nbytes</i> ] [ <i>file</i> ]<br>
27 78e51a8c 2005-01-14 devnull
28 78e51a8c 2005-01-14 devnull </table>
29 78e51a8c 2005-01-14 devnull <p><font size=+1><b>DESCRIPTION </b></font><br>
30 78e51a8c 2005-01-14 devnull
31 78e51a8c 2005-01-14 devnull <table border=0 cellpadding=0 cellspacing=0><tr height=2><td><tr><td width=20><td>
32 78e51a8c 2005-01-14 devnull
33 78e51a8c 2005-01-14 devnull <i>Tail</i> copies the named file to the standard output beginning at
34 78e51a8c 2005-01-14 devnull a designated place. If no file is named, the standard input is
35 78e51a8c 2005-01-14 devnull copied.
36 78e51a8c 2005-01-14 devnull <table border=0 cellpadding=0 cellspacing=0><tr height=5><td></table>
37 78e51a8c 2005-01-14 devnull
38 78e51a8c 2005-01-14 devnull Copying begins at position <tt><font size=+1>+</font></tt><i>number</i> measured from the beginning,
39 78e51a8c 2005-01-14 devnull or <tt><font size=+1>&#8722;</font></tt><i>number</i> from the end of the input. <i>Number</i> is counted in lines,
40 78e51a8c 2005-01-14 devnull 1K blocks or bytes, according to the appended flag <tt><font size=+1>l</font></tt>, <tt><font size=+1>b</font></tt>, or <tt><font size=+1>c</font></tt>.
41 78e51a8c 2005-01-14 devnull Default is <tt><font size=+1>&#8722;10l</font></tt> (ten ell).
42 78e51a8c 2005-01-14 devnull <table border=0 cellpadding=0 cellspacing=0><tr height=5><td></table>
43 78e51a8c 2005-01-14 devnull
44 78e51a8c 2005-01-14 devnull The further flag <tt><font size=+1>r</font></tt> causes tail to print lines from the end of
45 78e51a8c 2005-01-14 devnull the file in reverse order; <tt><font size=+1>f</font></tt> (follow) causes <i>tail</i>, after printing
46 78e51a8c 2005-01-14 devnull to the end, to keep watch and print further data as it appears.
47 78e51a8c 2005-01-14 devnull
48 78e51a8c 2005-01-14 devnull <table border=0 cellpadding=0 cellspacing=0><tr height=5><td></table>
49 78e51a8c 2005-01-14 devnull
50 78e51a8c 2005-01-14 devnull The second syntax is that promulgated by POSIX, where the <i>numbers</i>
51 78e51a8c 2005-01-14 devnull rather than the options are signed.<br>
52 78e51a8c 2005-01-14 devnull
53 78e51a8c 2005-01-14 devnull </table>
54 78e51a8c 2005-01-14 devnull <p><font size=+1><b>EXAMPLES </b></font><br>
55 78e51a8c 2005-01-14 devnull
56 78e51a8c 2005-01-14 devnull <table border=0 cellpadding=0 cellspacing=0><tr height=2><td><tr><td width=20><td>
57 78e51a8c 2005-01-14 devnull
58 78e51a8c 2005-01-14 devnull <tt><font size=+1>tail file<br>
59 78e51a8c 2005-01-14 devnull </font></tt>
60 78e51a8c 2005-01-14 devnull <table border=0 cellpadding=0 cellspacing=0><tr height=2><td><tr><td width=20><td>
61 78e51a8c 2005-01-14 devnull
62 78e51a8c 2005-01-14 devnull Print the last 10 lines of a file.<br>
63 78e51a8c 2005-01-14 devnull
64 78e51a8c 2005-01-14 devnull </table>
65 78e51a8c 2005-01-14 devnull <tt><font size=+1>tail +0f file<br>
66 78e51a8c 2005-01-14 devnull </font></tt>
67 78e51a8c 2005-01-14 devnull <table border=0 cellpadding=0 cellspacing=0><tr height=2><td><tr><td width=20><td>
68 78e51a8c 2005-01-14 devnull
69 78e51a8c 2005-01-14 devnull Print a file, and continue to watch data accumulate as it grows.<br>
70 78e51a8c 2005-01-14 devnull
71 78e51a8c 2005-01-14 devnull </table>
72 78e51a8c 2005-01-14 devnull <tt><font size=+1>sed 10q file<br>
73 78e51a8c 2005-01-14 devnull </font></tt>
74 78e51a8c 2005-01-14 devnull <table border=0 cellpadding=0 cellspacing=0><tr height=2><td><tr><td width=20><td>
75 78e51a8c 2005-01-14 devnull
76 78e51a8c 2005-01-14 devnull Print the first 10 lines of a file.<br>
77 78e51a8c 2005-01-14 devnull
78 78e51a8c 2005-01-14 devnull </table>
79 78e51a8c 2005-01-14 devnull
80 78e51a8c 2005-01-14 devnull </table>
81 78e51a8c 2005-01-14 devnull <p><font size=+1><b>SOURCE </b></font><br>
82 78e51a8c 2005-01-14 devnull
83 78e51a8c 2005-01-14 devnull <table border=0 cellpadding=0 cellspacing=0><tr height=2><td><tr><td width=20><td>
84 78e51a8c 2005-01-14 devnull
85 78e51a8c 2005-01-14 devnull <tt><font size=+1>/usr/local/plan9/src/cmd/tail.c<br>
86 78e51a8c 2005-01-14 devnull </font></tt>
87 78e51a8c 2005-01-14 devnull </table>
88 78e51a8c 2005-01-14 devnull <p><font size=+1><b>BUGS </b></font><br>
89 78e51a8c 2005-01-14 devnull
90 78e51a8c 2005-01-14 devnull <table border=0 cellpadding=0 cellspacing=0><tr height=2><td><tr><td width=20><td>
91 78e51a8c 2005-01-14 devnull
92 78e51a8c 2005-01-14 devnull Tails relative to the end of the file are treasured up in a buffer,
93 78e51a8c 2005-01-14 devnull and thus are limited in length.
94 78e51a8c 2005-01-14 devnull <table border=0 cellpadding=0 cellspacing=0><tr height=5><td></table>
95 78e51a8c 2005-01-14 devnull
96 78e51a8c 2005-01-14 devnull According to custom, option <tt><font size=+1>+</font></tt><i>number</i> counts lines from 1, and counts
97 78e51a8c 2005-01-14 devnull blocks and bytes from 0.
98 78e51a8c 2005-01-14 devnull <table border=0 cellpadding=0 cellspacing=0><tr height=5><td></table>
99 78e51a8c 2005-01-14 devnull
100 78e51a8c 2005-01-14 devnull <i>Tail</i> is ignorant of UTF.<br>
101 78e51a8c 2005-01-14 devnull
102 78e51a8c 2005-01-14 devnull </table>
103 78e51a8c 2005-01-14 devnull
104 78e51a8c 2005-01-14 devnull <td width=20>
105 78e51a8c 2005-01-14 devnull <tr height=20><td>
106 78e51a8c 2005-01-14 devnull </table>
107 78e51a8c 2005-01-14 devnull <!-- TRAILER -->
108 78e51a8c 2005-01-14 devnull <table border=0 cellpadding=0 cellspacing=0 width=100%>
109 78e51a8c 2005-01-14 devnull <tr height=15><td width=10><td><td width=10>
110 78e51a8c 2005-01-14 devnull <tr><td><td>
111 78e51a8c 2005-01-14 devnull <center>
112 78e51a8c 2005-01-14 devnull <a href="../../"><img src="../../dist/spaceglenda100.png" alt="Space Glenda" border=1></a>
113 78e51a8c 2005-01-14 devnull </center>
114 78e51a8c 2005-01-14 devnull </table>
115 78e51a8c 2005-01-14 devnull <!-- TRAILER -->
116 78e51a8c 2005-01-14 devnull </body></html>