最近用到的:每n行切為一個檔
2. Split file into multiple files with 3 lines each:
$ split -l 3 fileThe option -l specifies the number of lines per output file. Since the input file contains 7 lines, the output files contain 3, 3 and 1 respectively. The output files generated are:
$ ls x* xaa xab xac $ cat xaa Unix Linux AIXThe file "xab" contains the 4th till 6th line, and the file "xac" contains the last line.
沒有留言:
張貼留言