Date: Thu, 23 Jul 1998 09:54:05 +0300 (IDT) From: Eli Zaretskii To: Anne-Marie Chapman cc: djgpp AT delorie DOT com Subject: Re: Test Utilities In-Reply-To: <35B66B5D.1202@sympatico.ca> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Content-Transfer-Encoding: 8bit Precedence: bulk On Wed, 22 Jul 1998, Anne-Marie Chapman wrote: > I guess that this question is good for Nate or Eli. Thanks for the vote of confidence, but there're a lot more than us two here who know about these things, as I'm sure you will find soon enough. > Test 1 > (More test 1 stuff) > Test 2 > (More test 2 stuff …etc > > What I generate is files 1 to n each containing the stuff for that > test. I then run it through the gnu sort and cat it to another big > file. Seems like a job for `csplit' from the GNU Textutils (v2gnu/txt122b.zip). But if you really need to handle multiple occurences of the same "Test x" header, then I don't think `csplit' will support it. In such a case, Gawk (v2gnu/gwk303b.zip) is your friend. It could be also done with Sed, I think, but the script would be a bit complicated.