I have seen some nice file splitting utilites around that will let
you split by size,  but I have yet to find one that can do the
following:

Lets say I have a large text file I want to split into several
smaller chunks based on content. What imagine doing is insert the
same unique string in various places in the text file to indicate
where to split (this I can do by editing by hand w/editor or by
search/replace utility). What I am looking for then is a utility
that would let me first define a *split marker* w/ *unique string*
(either at the commandline and/or in config file), and when executed
the utility would read the text file and write to new file from
beginning of original file to first occurrence of *split marker*,
write output with basename.001, then continue reading original file
from where it left of  to next *split marker*, write output to new
file basename.002 and so on. Alternatively, use user defined
extension and increment the basename instead, like 0000001.xyz.

With a user defined  *split marker*, something like this could be
used for many purposes, say if you want to split a mail digest, or
any other large text files. It would be preferred if such program
will leave any formatting as is, thus not try to change CR to CR/LF
vice versa, no wrap etc, and it would also be useful if it could
*read* binary files the same way - without striping out or replacing
any high-bit characters. Also if it can run in batch mode (no screen
output/silent mode).

Anyone know if a utility like this exist?

I guess something like this can be done with the DOS ports of SED
and/or AWK, but both seem somewhat cryptic to me - w/ steep learning
curve. I'm sure it would be rewarding learning these utilities -
but... well I would prefer something simpler :)

All the best,
Bjorn

To unsubscribe from SURVPC send a message to [EMAIL PROTECTED] with 
unsubscribe SURVPC in the body of the message.
Also, trim this footer from any quoted replies.

Reply via email to