Gnus development mailing list
 help / color / mirror / Atom feed
From: Greg Farough <gregf@gnu.org>
To: ding@gnus.org
Subject: Re: Splitting mail between multiple addresses
Date: Wed, 16 Nov 2022 11:31:09 -0500	[thread overview]
Message-ID: <867czueu9e.fsf@gnu.org> (raw)
In-Reply-To: <87tu2zmt2h.fsf@isnotmyreal.name>

On Tue, Nov 15 2022, TRS-80 <lists.trs-80@isnotmyreal.name> wrote:

> Greg Farough <gregf@gnu.org> writes:
>
>> On Fri, Nov 11 2022, TRS-80 <lists.trs-80@isnotmyreal.name> wrote:
>>
>>> Hello list,
>>>
>>> I have a couple different email addresses (each as secondary select
>>> methods), with nntp (Gmane) as primary select method.
>>>
>>> I have some rules defined in `nnmail-split-methods', and then under each
>>> email, I have `nnimap-split-methods' set to 'default'.  This seemed to
>>> be the only way to get it to work.
>>>
>>> I would really like to set up splitting rules under each email address,
>>> that would be specific to mail coming to that address.  But I could not
>>> figure out how to do so.
>>>
>>> Any tips would be appreciated.
>>
>> I use something like this:
>>
>> (nnimap "Email"
>>         <snip>
>>         (nnmail-split-methods nnmail-split-fancy)
>> 	(nnimap-split-methods nnmail-split-fancy)
>> 	(nnmail-split-fancy (|
>> 	                    ("from" "ding@gnus.org" "INBOX.gnus")
>>                             ("from" "morgoth@mordorenterprises.org" junk)
>>                             ..and so on..
>>                             )))
>>
>> And that works.
>>
>> -g
>
> If I am understanding you correctly, I should be able to define both
> `nnmail-split-methods' and `nnimap-split-methods' /per email/?

Right. I have three email accounts in my
gnus-secondary-select-methods, and each one's rules for
nnmail-split-fancy apply only to that address.

In the example I gave, one of the *other* accounts getting a message
from morgoth@mordorenterprises.org would not necessarily send it to
junk. The only filters that apply are the ones I define for that
specific account.

> In my case, I am using simple (not fancy) but maybe it doesn't
> matter.

I remember really struggling to get it working, but it's been so long
that I don't remember how much I messed around with simple. Fancy
works great, though.

> Thanks a lot for the pointer!  I'll try it and report back how it goes.

You're welcome. Good luck!

-g

-- 
"We carry a new world here, in our hearts. That world is growing in
this minute."



      reply	other threads:[~2022-11-16 16:31 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-12  1:29 TRS-80
2022-11-13 15:14 ` Emanuel Berg
2022-11-14 21:07 ` Greg Farough
2022-11-16  4:17   ` TRS-80
2022-11-16 16:31     ` Greg Farough [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=867czueu9e.fsf@gnu.org \
    --to=gregf@gnu.org \
    --cc=ding@gnus.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).