diff options
Diffstat (limited to 'man/stat.1')
| -rw-r--r-- | man/stat.1 | 230 |
1 files changed, 230 insertions, 0 deletions
diff --git a/man/stat.1 b/man/stat.1 new file mode 100644 index 0000000..398b9b9 --- /dev/null +++ b/man/stat.1 @@ -0,0 +1,230 @@ +.\" Adapted for BNU from the GNU Coreutils 9.11 manual page; see doc/README.md. +.TH STAT "1" "2026-07-28" "BNU 9.11" "BNU Commands" +.SH NAME +stat \- display file or file system status +.SH SYNOPSIS +.B stat +[\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 +Display file or file system status. +.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#stat-L'\fB\-L, \-\-dereference\fP\X'tty: link' +follow links +.TP +\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#stat-f'\fB\-f, \-\-file\-system\fP\X'tty: link' +display file system status instead of file status +.TP +\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#stat--cached'\fB\-\-cached=MODE\fP\X'tty: link' +specify how to use cached attributes; +useful on remote file systems. See MODE below +.TP +\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#stat-c'\fB\-c, \-\-format=\,FORMAT\fP\X'tty: link'\/\fR +use the specified FORMAT instead of the default; +output a newline after each use of FORMAT +.TP +\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#stat--printf'\fB\-\-printf=FORMAT\fP\X'tty: link' +like \fB\-\-format\fR, but interpret backslash escapes, +and do not output a mandatory trailing newline; +if you want a newline, include \en in FORMAT +.TP +\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#stat-t'\fB\-t, \-\-terse\fP\X'tty: link' +print the information in terse form +.TP +\X'tty: link https://www.gnu.org/software/coreutils/stat#stat--help'\fB\-\-help\fP\X'tty: link' +display this help and exit +.TP +\X'tty: link https://www.gnu.org/software/coreutils/stat#stat--version'\fB\-\-version\fP\X'tty: link' +output version information and exit +.PP +The MODE argument of \fB\-\-cached\fR can be: always, never, or default. +\&'always' will use cached attributes if available, while +\&'never' will try to synchronize with the latest attributes, and +\&'default' will leave it up to the underlying file system. +.PP +The valid format sequences for files (without \fB\-\-file\-system\fR): +.TP +%a +permission bits in octal (see '#' and '0' printf flags) +.TP +%A +permission bits and file type in human readable form +.TP +%b +number of blocks allocated (see %B) +.TP +%B +the size in bytes of each block reported by %b +.TP +%C +SELinux security context string +.TP +%d +device number in decimal (st_dev) +.TP +%D +device number in hex (st_dev) +.TP +%Hd +major device number in decimal +.TP +%Ld +minor device number in decimal +.TP +%f +raw mode in hex +.TP +%F +file type +.TP +%g +group ID of owner +.TP +%G +group name of owner +.TP +%h +number of hard links +.TP +%i +inode number +.TP +%m +mount point +.TP +%n +file name +.TP +%N +quoted file name with dereference if symbolic link +.TP +%o +optimal I/O transfer size hint +.TP +%s +total size, in bytes +.TP +%r +device type in decimal (st_rdev) +.TP +%R +device type in hex (st_rdev) +.TP +%Hr +major device type in decimal, for character/block device special files +.TP +%Lr +minor device type in decimal, for character/block device special files +.TP +%t +major device type in hex, for character/block device special files +.TP +%T +minor device type in hex, for character/block device special files +.TP +%u +user ID of owner +.TP +%U +user name of owner +.TP +%w +time of file birth, human\-readable; \- if unknown +.TP +%W +time of file birth, seconds since Epoch; 0 if unknown +.TP +%x +time of last access, human\-readable +.TP +%X +time of last access, seconds since Epoch +.TP +%y +time of last data modification, human\-readable +.TP +%Y +time of last data modification, seconds since Epoch +.TP +%z +time of last status change, human\-readable +.TP +%Z +time of last status change, seconds since Epoch +.PP +Valid format sequences for file systems: +.TP +%a +free blocks available to non\-superuser +.TP +%b +total data blocks in file system +.TP +%c +total file nodes in file system +.TP +%d +free file nodes in file system +.TP +%f +free blocks in file system +.TP +%i +file system ID in hex +.TP +%l +maximum length of filenames +.TP +%n +file name +.TP +%s +block size (for faster transfers) +.TP +%S +fundamental block size (for block counts) +.TP +%t +file system type in hex +.TP +%T +file system type in human readable form +.SS "--terse is equivalent to the following FORMAT:" +.IP +%n %s %b %f %u %g %D %i %h %t %T %X %Y %Z %W %o %C +.SS "--terse --file-system is equivalent to the following FORMAT:" +.IP +%n %i %l %t %s %S %b %f %a %c %d +.PP +Your shell may have its own version of stat, which usually supersedes +the version described here. Please refer to your shell's documentation +for details about the options it supports. +.SH AUTHORS +Upstream GNU Coreutils documentation authors: +Written by Michael Meskes. +.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" +\fBstat\fP(2), \fBstatfs\fP(2), \fBstatx\fP(2) +.PP +.br +Upstream documentation <https://www.gnu.org/software/coreutils/stat> +.br +BNU documentation is available locally via: info \(aq(bnu) stat invocation\(aq |
