sort and uniq
Nov. 30th, 2011 07:40 pm![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Just a quickie - today I learned that instead of piping something through
Unfortunately this doesn't help when you're doing something like
sort
and then piping the output of that through uniq
, you can just use sort -u
, which will do both operations at once.Unfortunately this doesn't help when you're doing something like
sort | uniq -c | sort -n
to sort by the number of times a line appears, but it's still a nice tip. :)