procmail
[Top] [All Lists]

autoresponder

2001-04-11 02:46:55
Hi, I have some problems with a simple autoresponder:


SUBJ=`formail -xSubject:`      
:0 c
* $ ^To: .*(${OWNER1}|${OWNER2}).*
* ! ^List-
* ! ^(Mailing-List|Approved-By|BestServHost|Resent-(Message-ID|Sender)):
* ! ^Sender: (.*-errors@|owner-)
* ! ^X-[^:]*-List:
* !
^X-(Authentication-Warning|Loop|Sent-To|(Listprocessor|Mailman)-Version):
* ! ^Precedence: (junk|bulk|list)
* !$ ^From +$LOGNAME(@| |$)


{
  #CACHED=$VACMAILDIR/vacation.cache

  #:0 Wc: $CACHED$LOCKEXT
  #| /usr/bin/formail -rD 64536 $CACHED
  #:0 e
  #{ CACHED="" }

  :0 hfw
  |( /usr/bin/formail -r -I"Precedence: junk" \
        -I"From: $TOSENDER" -I"Subject: Re: ${SUBJ} (Auto Reply)" \
        -I"Reply-To: $TOSENDER" \
        -A"X-Loop: $ACCOUNT"; cat $HOME/.vacation.msg)\
  | /usr/sbin/sendmail -t

}



:0:
${DEFAULT}

OWNER1 and OWNER2 are alias of the same account. My first problem is to
set TOSENDER to the address in To:.
If someone send a mail to OWNER1 I would reply with OWNER1 in From.

The second problem is: the body of the mail that I receive is
duplicated.

Thanks

Michele
_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail

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