Is there a one-liner to split a text file into pieces / chunks after every Nth occurrence of a delimiter?
example: the delimiter below is "+"
entry 1
some more
+
entry 2
some more
even more
+
entry 3
some more
+
entry 4
some more
+
...
There are several million entries, so splitting on every occurrence of delimiter "+" is a bad idea. I want to split on, say, every 50,000th instance of delimiter "+".
Unix commands "split" and "csplit" just don't seem to do this...
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…