split a textfile after each n matches to a new file using sed or awk
- by ozz
i tried to split a file in parts of n matches each.
The file is just one line and the seperator is '<br>'
foo<br>bar<br>.....<br>
I just want to split the file in parts, where each file has 100 datasets (text plus <br>)( normaly 100 datasets, but at the end maybe less)
I already played around with this ... split-file-in-2-with-sed and this split-one-file-into-multiple-files-based-on-pattern
sed.exe -e "^.*.<br>{0,100}/g" < original.txt > first_half.txt
The split do not work an the result is only 1 file instead of many.