Skip to content
masterclass Buddy

Linux & Shell · Command

sort

sort orders lines from files or standard input and writes the result. Options control comparisons, fields, output, checking, merging, and duplicate handling.

Last updated

Syntax

sort [OPTION]... [FILE]...
sort [OPTION]... --files0-from=F

In-depth API docs are only for subscribers: parameters, examples, common mistakes and interview practice.

Subscribe
  • shuf(1)
  • uniq(1)

Source: sort(1) - Linux manual page. Checked 2026-11-03.