[H-GEN] Scripting guide
Jason Parker-Burlingham
jasonp at panix.com
Thu May 25 10:23:20 EDT 2006
On 5/25/06, Greg Black <gjb at gbch.net> wrote:
> On 2006-05-25, Jason Parker-Burlingham wrote:
> > What you want is:
> > awk '/([0-9]+\.)+[0-9]+/ {print $8,$13}' \
> > /var/log/apache/error.log.1
> >
> > I'm not sure if + is a GNU extension to awk, but [0-9][0-9]* will do in its
> > place.
>
> I was going to leave this topic alone, but this historical
> element got me in. I have nothing handy on my shelf prior to
> 1984, but I can assure you that basic regular expressions have
> used the '+' since at least that far back. I'm pretty sure it
> dates from the early 1970's, certainly before there was such a
> thing as GNU.
The reason I mentioned it is that i I'm remembering correctly---and NetBSD
grep bears me out---the plus sign is a part of the extended regular
expression syntax. My question was whether or not awk's extended regular
expression support was a GNU extension.
Looking back over what I wrote, that was much less than clear. Thanks for
your input.
jason, doing a lot of calls to egrep lately
More information about the General
mailing list