* regexp for nnmail-split-methods
@ 2008-11-03 17:56 Seweryn Kokot
2008-11-03 19:48 ` Reiner Steib
0 siblings, 1 reply; 5+ messages in thread
From: Seweryn Kokot @ 2008-11-03 17:56 UTC (permalink / raw)
To: ding
Hello,
I have a problem with setting nnmail-split-methods, namely I want that
messages from "foo@domain.com" address go to "nnml:mail.foo" mailbox and
all the other messages from ".*@domain.com" (except "foo@domain.com") go
to "nnml:mail.others" mailbox. Up to now I have such a regexp:
(setq nnmail-split-methods
'(("nnml:mail.others" "^From:.*[^f][^o][^o]@domain\\.com")
("nnml:mail.foo" "^From:.*foo@domain\\.com")
("nnml:mail.inbox" "")))
however there are some messages (for example from "bob@domain.com")
which end up in "nnml:mail.inbox".
How to create a regexp something like "^From:.*NOT(foo)@domain\\.com"?
Thanks in advance.
--
regards,
Seweryn
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: regexp for nnmail-split-methods
2008-11-03 17:56 regexp for nnmail-split-methods Seweryn Kokot
@ 2008-11-03 19:48 ` Reiner Steib
2008-11-03 21:51 ` Rupert Swarbrick
0 siblings, 1 reply; 5+ messages in thread
From: Reiner Steib @ 2008-11-03 19:48 UTC (permalink / raw)
To: ding
On Mon, Nov 03 2008, Seweryn Kokot wrote:
> I have a problem with setting nnmail-split-methods, namely I want that
> messages from "foo@domain.com" address go to "nnml:mail.foo" mailbox and
> all the other messages from ".*@domain.com" (except "foo@domain.com") go
> to "nnml:mail.others" mailbox. Up to now I have such a regexp:
>
> (setq nnmail-split-methods
> '(("nnml:mail.others" "^From:.*[^f][^o][^o]@domain\\.com")
> ("nnml:mail.foo" "^From:.*foo@domain\\.com")
> ("nnml:mail.inbox" "")))
>
> however there are some messages (for example from "bob@domain.com")
> which end up in "nnml:mail.inbox".
How about this?
(setq nnmail-split-methods
'(("nnml:mail.foo" "^From:.*foo@domain\\.com")
("nnml:mail.others" "^From:.*[^f][^o][^o]@domain\\.com")
("nnml:mail.inbox" "")))
Bye, Reiner.
--
,,,
(o o)
---ooO-(_)-Ooo--- | PGP key available | http://rsteib.home.pages.de/
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: regexp for nnmail-split-methods
2008-11-03 19:48 ` Reiner Steib
@ 2008-11-03 21:51 ` Rupert Swarbrick
2008-11-03 22:04 ` Ted Zlatanov
0 siblings, 1 reply; 5+ messages in thread
From: Rupert Swarbrick @ 2008-11-03 21:51 UTC (permalink / raw)
To: ding
[-- Attachment #1: Type: text/plain, Size: 401 bytes --]
Reiner Steib <reinersteib+gmane@imap.cc> writes:
> How about this?
>
> (setq nnmail-split-methods
> '(("nnml:mail.foo" "^From:.*foo@domain\\.com")
> ("nnml:mail.others" "^From:.*[^f][^o][^o]@domain\\.com")
> ("nnml:mail.inbox" "")))
>
> Bye, Reiner.
Hmm, except to which inbox should something from barfoo@domain.com go?
(Not that I've managed to think of a solution!)
Rupert
[-- Attachment #2: Type: application/pgp-signature, Size: 314 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: regexp for nnmail-split-methods
2008-11-03 21:51 ` Rupert Swarbrick
@ 2008-11-03 22:04 ` Ted Zlatanov
2008-11-04 20:29 ` Seweryn Kokot
0 siblings, 1 reply; 5+ messages in thread
From: Ted Zlatanov @ 2008-11-03 22:04 UTC (permalink / raw)
To: ding
On Mon, 03 Nov 2008 21:51:26 +0000 Rupert Swarbrick <rswarbrick@googlemail.com> wrote:
RS> Reiner Steib <reinersteib+gmane@imap.cc> writes:
>> How about this?
>>
>> (setq nnmail-split-methods
>> '(("nnml:mail.foo" "^From:.*foo@domain\\.com")
>> ("nnml:mail.others" "^From:.*[^f][^o][^o]@domain\\.com")
>> ("nnml:mail.inbox" "")))
RS> Hmm, except to which inbox should something from barfoo@domain.com go?
RS> (Not that I've managed to think of a solution!)
You should really consider fancy split methods, they can do this easily
without torturing regular expressions.
Ted
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: regexp for nnmail-split-methods
2008-11-03 22:04 ` Ted Zlatanov
@ 2008-11-04 20:29 ` Seweryn Kokot
0 siblings, 0 replies; 5+ messages in thread
From: Seweryn Kokot @ 2008-11-04 20:29 UTC (permalink / raw)
To: ding
Ted Zlatanov <tzz@lifelogs.com> writes:
> On Mon, 03 Nov 2008 21:51:26 +0000 Rupert Swarbrick <rswarbrick@googlemail.com> wrote:
>
> RS> Reiner Steib <reinersteib+gmane@imap.cc> writes:
>>> How about this?
>>>
>>> (setq nnmail-split-methods
>>> '(("nnml:mail.foo" "^From:.*foo@domain\\.com")
>>> ("nnml:mail.others" "^From:.*[^f][^o][^o]@domain\\.com")
>>> ("nnml:mail.inbox" "")))
>
> RS> Hmm, except to which inbox should something from barfoo@domain.com go?
> RS> (Not that I've managed to think of a solution!)
>
> You should really consider fancy split methods, they can do this easily
> without torturing regular expressions.
>
> Ted
Thanks for all replies, in this case I will use nnmail-split-fancy variable
since changing the order of lines in nnmail-split-methods doesn't help.
--
regards,
Seweryn
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2008-11-04 20:29 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-11-03 17:56 regexp for nnmail-split-methods Seweryn Kokot
2008-11-03 19:48 ` Reiner Steib
2008-11-03 21:51 ` Rupert Swarbrick
2008-11-03 22:04 ` Ted Zlatanov
2008-11-04 20:29 ` Seweryn Kokot
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).