~/sort(1)
en
NAME
sort - put lines in order
SYNOPSIS
sort [-rnu] [file ...]
DESCRIPTION
Sorts the lines it is given, or the ones handed down a pipe. Text order by
default, which puts capitals first the way every sort does; -n reads them
as numbers instead.
sort | uniq -c | sort -rn is the oldest pipeline there is, and it works
here.
OPTIONS
- -r
- backwards
- -n
- as numbers rather than as text
- -u
- one of each
EXAMPLES
map[cut -d:-f1 /etc/passwd | sort]
ls | sort -r
grep -rh is | sort | uniq -c | sort -rn