zhaowawj / ks

my knowledge summary
0 stars 0 forks source link

[linux command] sort uniq wc #3

Open zhaowawj opened 7 years ago

zhaowawj commented 7 years ago

1 sort

1.1 cat /etc/passwd | sort 1.2 field cat /etc/passwd | sort -t ':' -k 3 1.3 number ordering cat /etc/passwd | sort -t ':' -k 3 -n

2 uniq

1.1 ignore case uniq -i 1.2 count uniq -c

3 wc

1.1 line wc -l 1.2 line word character wc