'''UsingMutt''' BY Widgeteye
larrywyb/at/widgeteye.homeip.net
This is how '''I''' use Mutt and procmail. Whether it is the accepted way
I don't know but it ''''works'''' for me.
in the .forward file I have;
"|/usr/bin/procmail -f- || exit 75 #myusername"
#2) "|IFS=' ' && exec /usr/bin/procmail -f- || exit 75 #myusername"
For some reason the accepted line (#2) wouldn't work, I don't know if it's
because I use exim as mta or what but the line above that did work.
'''I have an executable file that calls Mutt, in that file I have;'''
-------------
#!/bin/bash<
>
formail -s procmail < /var/spool/mail/myusername<
>
rm /var/spool/mail/myusername<
>
mutt -y
-------------
Check man mutt to figure out the -y option.
'''In the .muttrc you need the following lines;'''
----------------------------
set folder=$HOME/mail #Make sure this directory exists<
>
mailboxes =almost-certainly-spam<
>
mailboxes =from #'''optional'''<
>
mailboxes =mbox<
>
mailboxes =probably-spam<
>
----------------------------
You'll notice these mailboxes match a couple of the mailboxes in the .procmailrc
file. '''''REMEMBER''''', every time you change a mailbox in the .procmail file
you have to make the same change in the .muttrc file.
Here's what I have in the .procmailrc file;
--------------------
PATH=/usr/bin:/bin:/usr/local/bin:.<
>
MAILDIR=$HOME/mail # You'd better make sure it exists<
>
DEFAULT=$MAILDIR/mbox #'''this is the default mailbox in the .muttrc file.'''<
>
LOGFILE=$MAILDIR/from<
>
LOCKFILE=$HOME/.lockmail<
>
# The lock file ensures that only 1 spamassassin invocation happens<
>
# at 1 time, to keep the load down.<
>
#<
>
:0fw: spamassassin.lock<
>
* < 256000<
>
| /usr/bin/spamassassin<
>
# Mails with a score of 15 or higher are almost certainly spam (with 0.05%<
>
# false positives according to rules/STATISTICS.txt). Let's put them in a<
>
# different mbox. (This one is optional.)<
>
:0:<
>
* ^X-Spam-Level: \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*<
>
# /dev/null<
>
almost-certainly-spam #'''this is the mailbox in the .muttrc file'''<
>
# All mail tagged as spam (eg. with a score higher than the set threshold)<
>
# is moved to "probably-spam".<
>
:0:<
>
* ^X-Spam-Status: Yes<
>
probably-spam #'''this is the mailbox in the .muttrc file'''<
>
# Work around procmail bug: any output on stderr will cause the "F" in "From"<
>
# to be dropped. This will re-add it.<
>
:0<
>
* ^^rom[ ]<
>
{<
>
LOG="*** Dropped F off From_ header! Fixing up. " <
>
:0 fhw<
>
| sed -e '1s/^/F/'<
>
}<
>
-------------
If you have questions I don't mind answering if I can. Write me at the email address at the top of the page.
And yes I know this page is ugly. :)