LC_ALL=C 加速你的排序
2019-05-23 本文已影响9人
热衷组培的二货潜
- So IMO, chances are you always want
sort -u
withLC_ALL=C
, if you want unique lines. And if you want that resulting list to be sorted in the user's sort order, pipe it to sort again:
LC_ALL=C sort -u | sort
LC_ALL=C sort | LC_ALL=C uniq -c | sort -k2