procmail
[Top] [All Lists]

Re: Mlocal

1999-12-15 23:52:13
ravi pina <ravi(_at_)cow(_dot_)org> writes:
i've set up sendmail to have procamil
be Mlocal so that i can have user+tag
work.  using a simple .procmailrc:

Did you remember to remove your .forward file?


PATH=/bin:/usr/bin:/usr/local/bin
MAILDIR=$HOME/Mail/`date +%y/%h`
MKDIR=`test -d $MAILDIR || mkdir $MAILDIR`

Um, that won't work.  Procmail attempts the chdir() only once, when
MAILDIR is assigned to.  The above should be changed to something like:

        DIR = "$HOME/Mail/`date +%y/%h`"

        # Most efficient way to test & mkdir
        :0 ihc
        * ! ? test -d $DIR
        |mkdir -p $DIR

        # Now that it exists, do the chdir
        MAILDIR = $DIR


BKP=`test -d $MAILDIR/backup || mkdir $MAILDIR/backup`
LOGFILE=$MAILDIR/logfile
...

So, what's the logfile contain?  Have you tried truning on VERBOSE?
If the logfile does't contain anything interesting, I would suggest you
switch to using a constant logfile (say, $HOME/.procmail.log) and put
VERBOSE=on right after that assignment.  You can change back once you
get everything else debugged.


...
:0:
$DEFAULT

This is superfluous, as procmail will attempt delivery to $DEFAULT if
it runs out of rcfile without successfully delivering the message.


Philip Guenther

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