help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to split (IMAP client side split) incoming mails into groups for


From: gnuforever
Subject: Re: How to split (IMAP client side split) incoming mails into groups for multiple emails addresses with Gnus
Date: Wed, 10 Jan 2018 23:02:36 +0000
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.3 (gnu/linux)

Emanuel Berg <address@hidden> writes:

> Are you currently getting them into the same
> group - from your example, the one
> called INBOX?

No. Each imap account has his own INBOX.
(nnimap-inbox "INBOX") ;; The one you mentioned is for the first email
(nnimap-inbox "address@hidden:INBOX") ;; This is the INBOX for the second email

> Also, hit `B q' in article mode to test where
> it will go

Thanks. It's pretty helpful

> PS. Also consider finding more descriptive
>     names than folder1 and folder2.

Good point



Alberto Luaces <address@hidden> writes:

> In my case it did not work correctly until I declare the main method as
> nnnil and my two IMAP servers as secondary.
>

Are you using the empty backend as described in the gnus documentation?

I changed my first select methods to nnnil like below:

(setq gnus-select-method '(nnnil ""))

(setq gnus-secondary-select-methods
      '((nnimap "address@hidden"
                (nnimap-address "imapserver")
                (nnimap-inbox "address@hidden:INBOX")
                (nnimap-split-methods default)
                (nnimap-expunge t)
                (nnimap-stream ssl)
                (nnimap-user "address@hidden"))))

(setq nnmail-split-methods
      '(("address@hidden:INBOX.gpg-users" "\\(To\\|Cc\\):address@hidden")
        ("address@hidden:INBOX.help-gnu-emacs" "\\(To\\|Cc\\):address@hidden")
        ("address@hidden:INBOX" "")))

I would expect from the code above to do this:
- A email to address@hidden would go to "gpg-users" group
- A email to address@hidden would go to "help-gnu-emacs" group
- The rest will go in the "INBOX" group

I did test the code for one imap account. The split doesn't even happen.
All emails go to "INBOX" group. The expressions for split are correct.

Is the code correct?



reply via email to

[Prev in Thread] Current Thread [Next in Thread]