fetching mail (but not fetchmail)

David Kelly dkelly at hiwaay.net
Fri Dec 24 06:33:45 UTC 2010

On Dec 24, 2010, at 12:01 AM, Chris Brennan wrote:

> Thanks but I I think maybe I wasn't entirely clear. With fetchmail (which is
> why I said but not fetchmail in the subject) I very well can download all my
> mail. For reading locally, on the console (not what I had in mind). Or is
> this where dovecot comes into play? To prepare the previously fetched mail
> and prepare it for pop/imap access?

Yes, that is exactly what he was saying. Fetchmail puts it where ever you tell it to. All you have to do is put the email where dovecot can find it in a format dovecot understands. You can think of dovecot as a remote controlled email reader, one which can be driven by Mail.app, Outlook, or Firefox. But in doing this you are not giving up the ability to do mail on your console.

When using maildir format both mutt and dovecot can operate out of the same mail repository at the same time.

For example I use ~/Maildir/ and the maildir format.

Also use procmail for initial sorting and filtering with bogofilter. In my .fetchmailrc like this:

	proto pop3
	mda "/usr/local/bin/procmail -d dkelly"

.procmailrc something like this:

MAILDIR=$HOME/Maildir/          #you'd better make sure it exists

# Make a copy of everything incoming:
:0 c

# Add a Lines: header if one is lacking, so mutt knows a message's size
:0 Bfh
* H ?? !^Lines:
* -1^0
*  1^1 ^.*$
| formail -A "Lines: $="

# bogofilter -u trains all tokens as spam or non-spam
:0 HB:
* ? bogofilter -u

# detect dupes
:0 Whc: msgid.lock
| formail -D 131072 msgid.cache

        # divert dupes
        :0 a:

# ultimate point of delivery

The above .procmail puts a copy of everything in ~/Mail_Backup/ just in case.

David Kelly N4HHE, dkelly at HiWAAY.net
Whom computers would destroy, they must first drive mad.

More information about the freebsd-questions mailing list