-n, --numeric-sort
Compare according to string numerical value.
An option of sortx.
Usage
sortx -n [FILE]...
sortx --numeric-sort [FILE]...Details
| Short | Long | Value | Default | Meaning |
|---|---|---|---|---|
-n | --numeric-sort | none | compare according to string numerical value |
Examples
Sort numbers by value rather than as text
sortx -n numbers.txtPrint the three largest numbers of a file
sortx -rn numbers.txt | headx -n 3Help in the terminal
gnux help sortx --numeric-sort