/************************************************************/
/*                        grep                              */
/************************************************************/

/* :SUMMARY: text search in object names and long texts
:PRIORITY: 5
:FEATURE: the grep command searches the object names of all classes,
longgrep also checks the contents of the ?LongText objects.
I think the grep behvaiour has changed from 4_5 to 4_7 to search tag 
names too - they are reported by the list function.
:HISTORY: 
:MODEL:     ?Grep T ?Text
:DATA:  mini.grep.ace
Grep inner
T "inner text"
T "further text"

LongText lt
minor inner text
***LongTextEnd***

:RESULT: 
gr: should find one object (inner)
    4_5  -  // Found 2 objects
            // 2 Active Objects 
    4_7h - // Found 3 objects
	   // 2 Active Objects
grlist: should list just one object (inner)
    4_5  - Grep:
            inner
           // 1 object listed, 1 not listable
           // 2 Active Objects 
    4_7h - Tag:
            inner
           Grep:
            inner
           // 2 object listed
           // 2 Active Objects

long: should find two objects (inner and lt)
    4_5  - // Found 3 objects
           // 3 Active Objects 
    4_7h - // Found 4 objects
           // 3 Active Objects

longlist:
    4_5  - LongText:
            lt
           Grep:
            inner
           // 2 object listed, 1 not listable
           // 3 Active Objects 
    4_7h - LongText:
            lt
           Tag:
            inner
           Grep:
            inner
           // 3 object listed
           // 3 Active Objects

:SCRIPT: */
grep: dbinit wspec.mini
  tace
    parse: do parse $data/mini.grep.ace
    clear: do clear
    gr: do grep inn
    grlist: list
    long: do longgrep inn
    longlist: list
  exit