sort
sort [OPTIONS] [--] [files]...
Display sorted concatenation of all FILE(s).
Options
--help-
Print help information
--version-
Print version information
--sort--human-numeric-sort,-h-
compare according to human readable sizes, eg 1M > 100k
--month-sort,-M-
compare according to month name abbreviation
--numeric-sort,-n-
compare according to string numerical value
--general-numeric-sort,-g-
compare according to string general numerical value
--version-sort,-V-
Sort by SemVer version number, eg 1.12.2 > 1.1.2
--random-sort,-R-
shuffle in random order
--dictionary-order,-d-
consider only blanks and alphanumeric characters
--merge,-m-
merge already sorted files; do not sort
--check,-c-
check for sorted input; do not sort
--check-silent,-C-
exit successfully if the given file is already sorted,and exit with status 1 otherwise.
--ignore-case,-f-
fold lower case to upper case characters
--ignore-nonprinting,-i-
ignore nonprinting characters
--ignore-leading-blanks,-b-
ignore leading blanks when finding sort keys in each line
--output=<FILENAME>,-o <FILENAME>-
write output to FILENAME instead of stdout
--reverse,-r-
reverse the output
--stable,-s-
stabilize sort by disabling last-resort comparison
--unique,-u-
output only the first of an equal run
--key,-k-
sort by a key
--field-separator,-t-
custom separator for -k
--zero-terminated,-z-
line delimiter is NUL, not newline
--parallel=<NUM_THREADS>-
change the number of threads running concurrently to NUM_THREADS
--buffer-size=<SIZE>,-S <SIZE>-
sets the maximum SIZE of each segment in number of sorted items
--temporary-directory=<DIR>,-T <DIR>-
use DIR for temporaries, not $TMPDIR or /tmp
--compress-program=<PROG>-
compress temporary files with PROG, decompress with PROG -d
--batch-size=<N_MERGE>-
Merge at most N_MERGE inputs at once.
--files0-from=<NUL_FILES>-
read input from the files specified by NUL-terminated NUL_FILES
--debug-
underline the parts of the line that are actually used for sorting