procmail
[Top] [All Lists]

Re: Denis Roegel's $FOUND

1997-10-05 13:15:11
First, let me thank those who replied to my query,
for it helps me to progress in what I want to achieve.

`David W. Tamkin' wrote

  Another matter to consider is what should happen if there are spaces or tabs
  in the value of $FOUND.  Perhaps it should be 
  
     RESULT=| myprogram "$FOUND" # in Philip's suggestion, or
     { RESULT = `myprogram "$FOUND" } # in Ed's
  
  That might be especially important if, for some reason, $FOUND contains only
  spaces.  Alternatively, you could change the condition to require that 
$FOUND
  have at least one character that is not a space, a tab, nor a newline:
  
    * FOUND ?? [^     ]

Actually, when I used what was suggested in earlier posts,
namely to match FOUND against `.', it failed. I mean, somehow
even when FOUND was empty, FOUND ?? . was true. I solved this
by matching FOUND against `..'. For me, this is not a problem
because I will always ensure that in the final rules something
significant will be more than a character long.

I will try the other suggestions, thanks.

Denis Roegel

<Prev in Thread] Current Thread [Next in Thread>