It appears that you're running an Ad-Blocker. This site is monetized by Advertising and by User Donations; we ask that if you find this site helpful that you whitelist us in your Ad-Blocker, or make a Donation to help aid in operating costs.

sort

sort is a standard Unix command line program that prints the lines of its input or concatenation of all files listed in its argument list in sorted order. Sorting is done based on one or more sort keys extracted from each line of input. By default, the entire input is taken as sort key. Blank space is taken used as default field separator. The -r flag will reverse the sort order.

Example:

Sort the current directory by file size

$ls -s | sort -n
96 Nov1.txt
128 _arch_backup.lst
128 _arch_backup.lst.tmp
1708 NMON
Posted on May 31st, 2014

Comments

( Posted)

Related Products

▼ Sponsored Links ▼
▲ Sponsored Links ▲
Donate Today