procmail
[Top] [All Lists]

Re: simple recipe question

1998-12-22 10:01:51
On Mon, 21 Dec 1998, Chuck Campbell wrote:

I have set up a simple recipe that I thought would do what I wanted, which is
to copy all incoming email to another machine, and then can the email.
The frist part seems to work fine, but I keep getting copies of the email
piling up (and subsequently filling my disk space, and causing email to 
then get bounced).

Is this not the right way to accomplish this?  Is there a better way?

Here is the .procmailrc

SHELL=/bin/sh
PATH=$HOME/bin:/bin:/usr/bin:/usr/local/bin:/usr/contrib/bin:.
MAILDIR=$HOME/Mail      # You'd better make sure it exists
DEFAULT=$MAILDIR/inbox
LOGFILE=$MAILDIR/procmail_log
LOCKFILE=$HOME/.lockmail
LOCKEXT=.lock
LINEBUF=20000

#  
# copy all mail to helium
# 
:0 c
! myname(_at_)[xxx(_dot_)xxx(_dot_)xxx(_dot_)xxx]

#
# can it all after forwarding
# 
:0 c
/dev/null

You're making it harder than it needs to be.  If all you're wanting to do
is forward the e-mail to another account, just do that.  If you use the c
flag (:0c), you'll still get a copy in the local inbox that you'll then
have to can.  So, just forward the mail and be done with it.


:0
! myname(_at_)[xxx(_dot_)xxx(_dot_)xxx(_dot_)xxx]


That's it!

Greg

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