Getting a 'grep' on myself

Getting a 'grep' on myself

Post by Tkil » Sun, 27 Jan 1991 02:58:49



I've a question for unix gurus.  I was creating a mail digest, and
was using 79 '=' signs as delimiters.  I then tried to use egrep to
knock it apart, with the command
  % egrep '^=\{79\}$' my-mail-digest
which failed pretty *ly to find any separaters.  I eventually
got around to trying
  % grep '^=\{79\}$' my-mail-digest
which worked as expected.

The real 'question' then, is why did egrep fail while grep works?

TiA,
Tony
--

Supporting:  Unix / DOS / VMS / Macintosh / "What's this?"
   ObQuote: "Lucretia, my reflection, dance the ghost with me..."
                                                      - Sisters Of Mercy

 
 
 

Getting a 'grep' on myself

Post by Barry Margol » Sun, 27 Jan 1991 05:52:30



Quote:>The real 'question' then, is why did egrep fail while grep works?

According to my manual (SunOS 4.0.3):

     egrep accepts regular expressions  of  the  same  sort  grep
     does,  except  for  \(, \), \n, \<, \>, \{, and \}, ...
--
Barry Margolin, Thinking Machines Corp.


{uunet,harvard}!think!barmar

 
 
 

1. Ooops (Was: Getting a 'grep' on myself)

Many apologies for the inappropriate posting.  Having received only
two RTFM replies, I count myself lucky to have caught it in time.

Thanks Anyway,
Tony.

P.S. apparently, egrep supports 'real' reg-exps, not the cheezy ones
     as described in the man page. :)
--

Supporting:  Unix / DOS / VMS / Macintosh / "What's this?"
   ObQuote: "Lucretia, my reflection, dance the ghost with me..."
                                                      - Sisters Of Mercy

2. LCD using gnome 2 or KDE 3

3. grep octal value (grep '\0145' /tmp/test) doesn't work !!

4. Problem: only 256 colors

5. Getting grep to ignore 'binary' files

6. Linux on an HP 7270 "Pavilion" with S3 ViRGE

7. How to make grep select both lines using only a single 'grep' command

8. My button on ghostview doesnt work?

9. 'diff' option like 'grep -q'?

10. Combining 'find' and 'grep' or searching in general

11. Q: grep 'foo' NOT followed by 'bar'

12. put myself in group 'root'?