procmail
[Top] [All Lists]

RE: error question, brain-picking questions

1997-06-30 07:32:00
On Friday, June 27, 1997 3:50 PM, era eriksson [SMTP:era(_at_)iki(_dot_)fi] 
wrote:

On Fri, 27 Jun 1997 12:37:12 +0200, Dallman Ross
<rossd(_at_)heidelberg-emh11(_dot_)army(_dot_)mil> wrote:
 >    procmail: Extraneous filter-flag ignored

These are hard to debug without a verbose log, and usually easy when
you have one. Try running with VERBOSE=yes (perhaps temporarily using
a different log file -- one good reason for splitting your .procmailrc

Okay, I'll do just that when I get back to sweating those details.  Thanks!

into smaller files you can INCLUDERC from the main file and debug on

I do use INCLUDERC now, but just once.  Are you implying it can be
used several times in the same procmail run?  Interesting.  (I use it
to read date, saved once a day as yymmdd to a file, rather than
running `date` every time procmail is invoked.)

`make recommend' usually does the right thing (check the INSTALL docs).

Okay, I remember reading that now.  Good, thanks.


 > fine), I want to answer the person, "thank you for
 > writing to dman(_at_)netcom(_dot_)com"; but if it is the 
ix.urz.uni-heidelberg.de
 > server that forwarded, then it should be "thank you for
 > writing to o30(_at_)ix(_dot_)urz(_dot_)uni-heidelberg(_dot_)de"; etc., etc.

You can usually grep this out of the very first Received: lines. This
depends to some extent of the MTAs of the forwarding sites but you can
at least expect to see something like "Received: from xyz.netcom.com"
near the beginning of the headers, and extrapolate from that. 

I am interested in developing a highly efficient and elegant way
to do this.  I find typical kludges to be easy but ugly, while
well-thought-through, elegant solutions are so much more beautiful.  :-)


 >    sed "s/\$SUBJ/$SUBJ/" $HOME/etc/.acknowledgment
 > 
 > I just noticed that in mail that came with an ampersand already
 > in the subject, though, that caused the sed statement to reflect
 > back the rest of the line where the ampersand was.

SUBJ=`echo "$SUBJ" | sed -e 's/&/\\&/g'` should take care of that.
Simpler equivalent commands could perhaps be devised. There are other
funny characters you might want to be wary of, such as anything with a
backslash. (See the sed manual for which characters are special in the
target portion of the s/// command. And BTW, for the truly paranoid,
's/&/\\\&/g' will prevent the substitution of & with & :-)

Hope this helps,

Yes, it does.  Thanks again!

-- 
Dallman Ross, Programmer-Analyst, IMO/ISSO
26th Area Support Group - S1 Automation Branch
<rossd(_at_)heidelberg-emh11(_dot_)army(_dot_)mil>
<dman(_at_)netcom(_dot_)com>
Tel.: 011-49-6221-176779 . DSN: 373-6779

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