cheat-fork-echo/cheat/cheatsheets/csplit

6 lines
182 B
Text
Raw Normal View History

# Split a file based on pattern
csplit input.file '/PATTERN/'
# Use prefix/suffix to improve resulting file names
csplit -f 'prefix-' -b '%d.extension' input.file '/PATTERN/' '{*}'