Announcements and discussions for Gnus, the GNU Emacs Usenet newsreader
 help / color / mirror / Atom feed
* Splitting with SpamAssassin and group parameters
@ 2002-08-19 21:51 Kirk Strauser
       [not found] ` <87u1lq7b82.fsf@emacswiki.org>
  0 siblings, 1 reply; 2+ messages in thread
From: Kirk Strauser @ 2002-08-19 21:51 UTC (permalink / raw)


I'm recently installed SpamAssassin on my mailserver, and want to start
using it to split my email in Gnus.  The problem I'm running into is that it
seems as if the whole world splits their mail with `nnmail-split-fancy', but
I'm using

    (setq nnmail-split-methods        'bbdb/gnus-split-method)
    (setq bbdb/gnus-split-nomatch-function 'gnus-group-split)

and group parameters.  So far, I've gleaned that I need to add a split-spec
group parameter to a new group (`mail.spam', say) so that email with a
header line `X-Spam-Status: Yes' gets sent to that group.  However, I can't
seem to get the correct syntax for doing such a thing; my mail either
doesn't get split as expected or everything gets sent to the bogus group.

So, does anyone use group parameters enough to know how to make

    (x-spam-status "Yes" "mail.spam")

work the way I want it to?
-- 
Kirk Strauser


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Splitting with SpamAssassin and group parameters
       [not found] ` <87u1lq7b82.fsf@emacswiki.org>
@ 2002-08-20 15:24   ` Kirk Strauser
  0 siblings, 0 replies; 2+ messages in thread
From: Kirk Strauser @ 2002-08-20 15:24 UTC (permalink / raw)



At 2002-08-19T22:08:45Z, Alex Schroeder <alex@emacswiki.org> writes:

> I use fancy splitting AND bbdb splitting.  Why don't you give it a try?  I
> am sure you could add gnus-group-split to the fancy splitting rules.  Here
> is some code to get you started:

Thanks for the shove in the right direction!  Here's my new splitting
algorithm:

;; ----------------------------------------
;; %%% NEW SPLIT RULES (2002-08-20)
(setq
 nnmail-split-methods        'bbdb/gnus-split-method
 bbdb/gnus-split-nomatch-function 'nnmail-split-fancy

 ;; Ideas from http://www.emacswiki.org/cgi-bin/wiki.pl?SplitMailUsingBbdb
 nnmail-split-fancy
 `(|
     ("x-spam-status" "Yes" "mail.spam")
     (: (lambda ()
	  (car (gnus-group-split))))
     "mail.misc")
)
;; ----------------------------------------

Now my mail is filter as follows:

1) Addresses matching entries in my BBDB are explicitly split into the
   group specified in `gnus.private'

2) Mails are then matched against any fancy splits I've defined

3) Next, mails are split according to the rules defined in my group
   parameters

4) Anything remaining goes to mail.misc

Thanks again, Alex!
-- 
Kirk Strauser
The Strauser Group - http://www.strausergroup.com/


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2002-08-20 15:24 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-08-19 21:51 Splitting with SpamAssassin and group parameters Kirk Strauser
     [not found] ` <87u1lq7b82.fsf@emacswiki.org>
2002-08-20 15:24   ` Kirk Strauser

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).