Linux basics - linux command: csplit

Linux basics-linux command: csplit
csplit (context split)
function description: split files.

Syntax: csplit [-kqsz][-b<output format>][-f<output prefix string>][-n<output file name digits>][--help][--version][file] [Template style...]

Supplementary description: After cutting the file according to the specified template style, save it as files named xx00, xx01, xx02... respectively. If the given filename is "-", the csplit instruction reads data from the standard input device.

Parameters:
  -b<output format> or --suffix-format=<output format> The default output format has the file name xx00,xx01...etc. You can change the output file name by changing the <output format> .
  -f<output prefix string> or --prefix=<output prefix string> The default output prefix string whose file name is xx00,xx01...etc. If you specify the output prefix string as "hello", the output file name will become hello00, hello01...etc.
  -k or --keep-files keep files, even if an error occurs or execution is interrupted, the files that have been output and saved cannot be deleted.
  -n <output file name digits> or --digits=<output file name digits> The default output file name digits are xx00, xx01...etc. If you specify the output file name digits as "3", the output file name will become xx000,xx001... Wait.
  -q or -s or --quiet or --silent do not display the command execution process.
  -z or --elide-empty-files Delete files of length 0 Byte.
  --help Online help.
  --version Display version information.

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=326391880&siteId=291194637