Now I enhanced my filegrep.vdm a bit.
The main new feature is the possibility to grep for whole divisions.
A typical real life example could be:
searching or filtering a standard mail export file.
Every mail in such a file is started with a line like the following:
From name@... Sat Sep 14 22:01:32 2002
and followed by the header and body of the mail.
Using a divider/title search string like
"|
(included in the code as example, but initially commented out.)
you can extract all mails containing a given search string.
The menu dialog now looks like:
The following string is
() a title line or
() a divider
Title/div. search string: __________________
using
() pattern matching or
() regular expressions
Contents search string: __________________
using
() pattern matching or
() regular expressions
[] Case sensitive
[] Search &from beginning of file (or block); else from cursor
[] Only within the highlighted &block
[] List divider lines and found contents; else only divider lines
[] List the whole found divison (not only the matching lines)
The macro can be found here:
http://ziemski.privat.t-online.de/vedit/macros/filegrep.vdm
Christian