官术网_书友最值得收藏!

The sort command

This command sorts the contents of a text file, line by line. The options are as follows:

  • -n: Sorts as per the numeric value
  • -d: Sorts as per the dictionary meaning
  • -h: Compares as per the human-readable numbers (for example, 1K 2G)
  • -r: Sorts in the reverse order
  • -t: Option to specify a delimiter for fields
  • +num: Specifies sort field numbers
  • -knum: Specifies sort field numbers
  • $ sort -k4 sample.txt: This will sort according to the fourth field
主站蜘蛛池模板: 南靖县| 镇远县| 凤台县| 张家港市| 鄂尔多斯市| 怀来县| 呈贡县| 封丘县| 汉中市| 溧阳市| 都匀市| 基隆市| 新乐市| 进贤县| 甘洛县| 巴南区| 称多县| 三河市| 吉水县| 双牌县| 江口县| 加查县| 右玉县| 鱼台县| 曲松县| 荣昌县| 罗山县| 淳安县| 石柱| 吴江市| 资源县| 鄢陵县| 东台市| 怀仁县| 吉木乃县| 松桃| 绥宁县| 东港市| 策勒县| 娄底市| 临猗县|