Re: Gecos field regex - ignored?

Top Page
Delete this message
Reply to this message
Author: Philip Hazel
Date:  
To: Hans Grobler
CC: exim-users
Subject: Re: Gecos field regex - ignored?
On Mon, 21 Oct 1996, Hans Grobler wrote:

> gecos_name = "$1"
> gecos_pattern = "^?\,^?"


No, not right. Try

gecos_name = "$1"
gecos_pattern = "^([^,]*),"

You need round brackets to pick out things for $1, $2, etc. That r.e.
reads

  ^     match start of text
  (     start of text for $1
  [^,]  match a character that is not a ,
  *     repeated zero or more times
  )     end of $1 text 
  ,     match a comma    



--
Philip Hazel                   University Computing Service,
ph10@???             New Museums Site, Cambridge CB2 3QG,
P.Hazel@???          England.  Phone: +44 1223 334714