Tag: TR WC split cut
Cut intercept
Cut-d:-f+ number + file to take the first paragraph of the file, with a comma between multiple numbers
Cut-c intercept the first few characters (3-5 3 to 5)
Sort sorts
-T delimiter
-U to repeat
-N Sort by number
-K Segments (-k3,5---3 to 5)
SORT-T:-k3-n/etc/passwd//The number of the 3rd paragraph, plus r reverse order
WC to find the number of rows
-L-----To find the number of rows
-W-----How many words (separated by blanks)
-m-----number of characters (including line break)
Uniq and Tee
Uniq to repeat, you can also calculate how many rows are duplicated (repeated must be together before you can, so there are multiple repetitions that must be sorted first)
-C Calculated Quantity
Tee redirection plus dual output, middle pipe symbol "|"
650) this.width=650; "src=" Http://s5.51cto.com/wyfs02/M00/82/88/wKiom1dX3_jysrzVAACdmHYnPL8942.png "title=" 1.png " alt= "Wkiom1dx3_jysrzvaacdmhynpl8942.png"/>
TR replacement and split cutting
TR-----Replacement
650) this.width=650; "src=" Http://s5.51cto.com/wyfs02/M00/82/87/wKioL1dX4Q_xiBlyAAGpjVXdX3A879.png "style=" float: none; "title=" 2.png "alt=" Wkiol1dx4q_xiblyaagpjvxdx3a879.png "/>
Split cut
-l----delimited by number of rows
-b----separated by size, except B, other units need to be added M,GB
650) this.width=650; "src=" Http://s5.51cto.com/wyfs02/M01/82/88/wKiom1dX4Aaz755CAAA-LaMeQFk793.png "title=" 3.png " Style= "Float:none;" alt= "Wkiom1dx4aaz755caaa-lameqfk793.png"/>
Shell Common Commands