Gnus development mailing list
 help / color / mirror / Atom feed
* new spam.el spam-split feature: specify test
@ 2003-04-19 20:55 Ted Zlatanov
  0 siblings, 0 replies; only message in thread
From: Ted Zlatanov @ 2003-04-19 20:55 UTC (permalink / raw)


I added this earlier in the week, but wanted to test it first.

You can now give spam-split a parameter, e.g. 'spam-use-regex-headers.
Why is this useful?

Take these split rules from a setq statement (not exactly mine, but
close enough):

 nnimap-split-fancy '(|
		      (any "ding" "ding")
		      (: spam-split)
		      ;; default mailbox
		      "mail")

Now, the problem is that you want all ding messages to make it to the
ding folder.  But that will let obvious spam (detected by
SpamAssassin, and spam-use-regex-headers on my side) through, when
it's sent to the ding list.  On the other hand, some messages to the
ding list are from a mail server in the blackhole list, so the
invocation of spam-split can't be before the ding rule.

I decided to let SpamAssassin headers supercede ding rules, but all
other spam-split rules (including a second invocation of the
regex-headers check) will be after the ding rule.

 nnimap-split-fancy '(|
		      (: spam-split 'spam-use-regex-headers)
		      (any "ding" "ding")
		      (: spam-split)
		      ;; default mailbox
		      "mail")

Basically, this lets you invoke specific spam-split checks depending
on your particular needs.  You don't have to throw all mail into all
the spam tests.  Another reason why this is nice is that messages to
mailing lists you have rules for don't have to have resource-intensive
blackhole checks performed on them.  You could also specify different
spam checks for your nnmail split vs. your nnimap split.  Go crazy.

You still have to have spam-use-regex-headers set to t, even if you
specifically invoke spam-split with it.  The reason is that when
loading spam.el, some conditional loading is done depending on what
spam-use-xyz variables you have set.

Thanks
Ted




^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2003-04-19 20:55 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-04-19 20:55 new spam.el spam-split feature: specify test Ted Zlatanov

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