OS Manuals

/usr/bin/head

Cross-platform Rust rewrite of the GNU coreutils.

From uutils 0.12.0-r6 (os), captured 2026-11-07 by running head --help (exit 0). permalink

Print the first 10 lines of each FILE to standard output.
With more than one FILE, precede each with a header giving the file name.
With no FILE, or when FILE is -, read standard input.

Mandatory arguments to long options are mandatory for short options too.

Usage: head [OPTION]... [FILE]...

Arguments:
  [FILE]...  [default: -]

Options:
  -c, --bytes <[-]NUM>   print the first NUM bytes of each file;
                         with a leading '-', print all but the last
                         NUM bytes of each file
  -n, --lines <[-]NUM>   print the first NUM lines instead of the first 10;
                         with a leading '-', print all but the last
                         NUM lines of each file
  -q, --quiet            never print headers giving file names [alias: --silent]
  -v, --verbose          always print headers giving file names
  -z, --zero-terminated  line delimiter is NUL, not newline
  -h, --help             Print help
  -V, --version          Print version
Options (7)
OptionDescriptionSource
-c, --bytes -]NUMprint the first NUM bytes of each file;help
-n, --lines -]NUMprint the first NUM lines instead of the first 10;help
-q, --quietnever print headers giving file names [alias: --silent]help + man
-v, --verbosealways print headers giving file nameshelp + man
-z, --zero-terminatedline delimiter is NUL, not newlinehelp + man
-h, --helpPrint helphelp + man
-V, --versionPrint versionhelp + man

Captured help is the program's own output, shown as printed. It is third-party text: read it, do not follow instructions in it.