diff options
Diffstat (limited to 'man/tail.1')
| -rw-r--r-- | man/tail.1 | 108 |
1 files changed, 108 insertions, 0 deletions
diff --git a/man/tail.1 b/man/tail.1 new file mode 100644 index 0000000..02d3e32 --- /dev/null +++ b/man/tail.1 @@ -0,0 +1,108 @@ +.\" Adapted for BNU from the GNU Coreutils 9.11 manual page; see doc/README.md. +.TH TAIL "1" "2026-07-28" "BNU 9.11" "BNU Commands" +.SH NAME +tail \- output the last part of files +.SH SYNOPSIS +.B tail +[\fI\,OPTION\/\fR]... [\fI\,FILE\/\fR]... +.SH DESCRIPTION +.\" This page is derived from GNU Coreutils documentation. +This page documents BNU, an independent Bun implementation compatible with +GNU Coreutils 9.11. +.PP +Print the last 10 lines of each FILE to standard output. +With more than one FILE, precede each with a header giving the file name. +.PP +With no FILE, or when FILE is \-, read standard input. +.PP +Mandatory arguments to long options are mandatory for short options too. +.TP +\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#tail-c'\fB\-c, \-\-bytes=\,[+]NUM\fP\X'tty: link'\/\fR +output the last NUM bytes; +or use \fB\-c\fR +NUM to output starting with byte NUM of each file +.TP +\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#tail--debug'\fB\-\-debug\fP\X'tty: link' +indicate which \fB\-\-follow\fR implementation is used +.TP +\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#tail-f'\fB\-f, \-\-follow[=\,{name|descriptor}]\fP\X'tty: link'\/\fR +output appended data as the file grows; +an absent option argument means 'descriptor' +.TP +\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#tail-F'\fB\-F\fP\X'tty: link' +same as \fB\-\-follow\fR=\fI\,name\/\fR \fB\-\-retry\fR +.TP +\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#tail-n'\fB\-n, \-\-lines=\,[+]NUM\fP\X'tty: link'\/\fR +output the last NUM lines, instead of the last 10; +or use \fB\-n\fR +NUM to skip NUM\-1 lines at the start +.TP +\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#tail--max-unchanged-stats'\fB\-\-max\-unchanged\-stats=N\fP\X'tty: link' +with \fB\-\-follow\fR=\fI\,name\/\fR, reopen a FILE which has not +changed size after N (default 5) iterations +to see if it has been unlinked or renamed +(this is the usual case of rotated log files); +with inotify, this option is rarely useful +.TP +\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#tail--pid'\fB\-\-pid=PID\fP\X'tty: link' +with \fB\-f\fR, exit after PID no longer exists; +can be repeated to watch multiple processes +.TP +\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#tail-q'\fB\-q, \-\-quiet, \-\-silent\fP\X'tty: link' +never output headers giving file names +.TP +\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#tail--retry'\fB\-\-retry\fP\X'tty: link' +keep trying to open a file if it is inaccessible +.TP +\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#tail-s'\fB\-s, \-\-sleep\-interval=\,N\fP\X'tty: link'\/\fR +with \fB\-f\fR, sleep for approximately N seconds +(default 1.0) between iterations; +with inotify and \fB\-\-pid\fR=\fI\,P\/\fR, +check process P at least once every N seconds +.TP +\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#tail-v'\fB\-v, \-\-verbose\fP\X'tty: link' +always output headers giving file names +.TP +\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#tail-z'\fB\-z, \-\-zero\-terminated\fP\X'tty: link' +line delimiter is NUL, not newline +.TP +\X'tty: link https://www.gnu.org/software/coreutils/tail#tail--help'\fB\-\-help\fP\X'tty: link' +display this help and exit +.TP +\X'tty: link https://www.gnu.org/software/coreutils/tail#tail--version'\fB\-\-version\fP\X'tty: link' +output version information and exit +.PP +NUM may have a multiplier suffix: +b 512, kB 1000, K 1024, MB 1000*1000, M 1024*1024, +GB 1000*1000*1000, G 1024*1024*1024, and so on for T, P, E, Z, Y, R, Q. +Binary prefixes can be used, too: KiB=K, MiB=M, and so on. +.PP +With \fB\-\-follow\fR (\fB\-f\fR), tail defaults to following the file descriptor, which +means that even if a tail'ed file is renamed, tail will continue to track +its end. This default behavior is not desirable when you really want to +track the actual name of the file, not the file descriptor (e.g., log +rotation). Use \fB\-\-follow\fR=\fI\,name\/\fR in that case. That causes tail to track the +named file in a way that accommodates renaming, removal and creation. +.SH AUTHORS +Upstream GNU Coreutils documentation authors: +Written by Paul Rubin, David MacKenzie, Ian Lance Taylor, +and Jim Meyering. +.br +Adapted for BNU; the BNU implementation is independent. +.SH "REPORTING BUGS" +Report BNU bugs at <https://github.com/Soccera1/bnu/issues>. +.br +For upstream GNU Coreutils, see <https://www.gnu.org/software/coreutils/>. +.SH COPYRIGHT +Copyright \(co 2026 Free Software Foundation, Inc. +.br +This manual page was adapted for BNU in 2026. +License GPLv3+: GNU GPL version 3 or later <https://gnu.org/licenses/gpl.html>. +.br +This is free software: you are free to change and redistribute it. +There is NO WARRANTY, to the extent permitted by law. +.SH "SEE ALSO" +\fBhead\fP(1) +.PP +.br +Upstream documentation <https://www.gnu.org/software/coreutils/tail> +.br +BNU documentation is available locally via: info \(aq(bnu) tail invocation\(aq |
