Gnus development mailing list
 help / color / mirror / Atom feed
* Sieve support in Gnus, sample implementation
@ 2001-02-19  3:45 NAGY Andras
  0 siblings, 0 replies; only message in thread
From: NAGY Andras @ 2001-02-19  3:45 UTC (permalink / raw)


[-- Attachment #1: Type: text/plain, Size: 1830 bytes --]

Gnus has a nice feature, splitting (and fancy splitting), for sorting
incoming mail to folders on the client side.  Furthermore, Gnus has
another feature, group mail splitting, which allows the user to store
splitting info in group paramteres, that is, keep everything related
to a particular mailing list (splitting rules, to-address, admin
address, comments, styles etc) in one place.

Sieve is a mail filtering language, available on certain IMAP servers,
and enables server side mail filtering.  Sieve's server side sorting
is more efficient than Gnus' client side, but the user has to maintain
a separate sieve script in addition to the other group paramteres.

So why not combine these two things, and let Gnus auto-generate a
Sieve script, based on group paramters?

Why not, indeed.  :)

Below is a quick hack (no concepts, docs or whatever) demonstrating a
possible implementation.  This allows you to write things like

 (sieve address "sender" "owner-ding@hpc.uh.edu")

or

 (sieve anyof ( (address "sender" ("quux@bar.com" "boss@bar.com")
                (size :over 12K))))

among group parameters, and integrate them into your sieve script,
resulting in:

if anyof (address "sender" ["quux@bar.com", "boss@bar.com"] ) {
        fileinto "INBOX.mail.bar";
}
elsif address "sender" "owner-ding@hpc.uh.edu" {
        fileinto "INBOX.list.ding";
}



Usage: create an empty, or modify your existing script to look like:

--->
require "fileinto";

front of your script

## Begin Gnus Sieve Script

# i think two newlines are needed here
## End Gnus Sieve Script

rest of your script
<---

Define group paramters, and do an M-x sieve-update, then upload your
script.


Opinions, suggestions (both technical and conceptual), patches etc are
welcome.  BTW, any ideas why lines 55-56 (commented out) not working?



Andras



[-- Attachment #2: sieve.el --]
[-- Type: application/emacs-lisp, Size: 1697 bytes --]

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

only message in thread, other threads:[~2001-02-19  3:45 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-02-19  3:45 Sieve support in Gnus, sample implementation NAGY Andras

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