Re: question about getmailrc

Charles Cazabon <[email protected]> Tue, 8 Mar 2022 07:57:33 -0600
Newsgroups gmane.mail.getmail.user
Message-ID <[email protected]>
Marc Lobelle <[email protected]> wrote:
> 
> Currently my getmailrc is

Hi - not sure what all the slashes in your text were for.  You might want to
check your mail client settings.  It makes it pretty difficult to read.

> [retriever]//
> type=SimpleIMAPSSLRetriever
[...]
> [destination]
> type=Maildir
> path=/home/ml/Maildir/

> /mailboxes=("boîte de réception","courrier indésirable",)
> 
> I assume I would recover the contents of the two remote mailxoxes in my
> local inbox

Yes.

, but how could I  get the contents of "courrier indésirable" in
> "/home/ml/Maildir/.anteroom" ?

There are a number of ways.  The easiest is to have two getmailrc files, the
above plus another similar one that only pulls from the other folder and
delivers to the other local maildir, and then run getmail with two --rcfile/-r
arguments.

Another is to use a sorting/filtering MDA like maildrop as your delivery
target, and configure it to deliver to the two maildirs based on Delivered-To:
headers or whatever other clues are present in the messages.

getmail also has the MultiGuesser destination which can do basic sorting and
choose a destination based on that.

The first two "How do I..." items in the getmail FAQ explain this.

Charles
-- 
-----------------------------------------------------------------------
Charles Cazabon
GPL'ed software available at:               http://pyropus.ca/software/
-----------------------------------------------------------------------