Gnus development mailing list
 help / color / mirror / Atom feed
From: Simon Josefsson <jas@extundo.com>
Subject: Re: Sieve support?
Date: Thu, 01 Nov 2001 01:53:41 +0100	[thread overview]
Message-ID: <iluady7tip6.fsf@dhcp128.extundo.com> (raw)
In-Reply-To: <iluk7xprvt6.fsf@barbar.josefsson.org> (Simon Josefsson's message of "Sun, 21 Oct 2001 15:01:41 +0200")

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset=iso-2022-7bit-dos, Size: 7551 bytes --]

Simon Josefsson <jas@extundo.com> writes:

> Does anyone think adding NAGY Andras and my Sieve stuff [1] to Gnus
> would be a good idea?

Noone complained so I added it.  Unless you press `D u' or `D g' in
the group buffer, you should never see it.  Kudos to NAGY Andras for
the work on gnus-sieve.el!

Some documentation:
\f
In the "Group Parameters" section:

`sieve'
     This parameter contains a Sieve test that should match incoming
     mail that should be placed in this group.  From this group
     parameter, a Sieve `IF' control structure is generated, having the
     test as the condition and `fileinto "group.name";' as the body.

     For example, if the INBOX.list.sieve group has the `(sieve address
     "sender" "sieve-admin@extundo.com")' group parameter, when
     translating the group parameter into a Sieve script (*note Sieve
     Commands::) the following Sieve code is generated:

            if address \"sender\" \"sieve-admin@extundo.com\" {
                    fileinto \"INBOX.list.sieve\";
            }

     The Sieve language is described in RFC 3028.  *Note Top:
     (sieve)Top.
\f
In the "Misc Group Stuff" chapter, a new node was added:

Sieve Commands
--------------

   Sieve is a server-side mail filtering language.  In Gnus you can use
the `sieve' group parameter (*note Group Parameters::) to specify sieve
rules that should apply to each group.  Gnus provides two commands to
translate all these group parameters into a proper Sieve script that
can be transfered to the server somehow.

   The generated Sieve script is placed in `gnus-sieve-file' (by
default `~/.sieve').  The code Gnus generates is placed between two
delimiters, `gnus-sieve-region-start' and `gnus-sieve-region-end', so
you may write additional Sieve code outside these delimiters that will
not be removed the next time you regenerate the Sieve script.

   *Note Top: (sieve)Top.

`D g'
     Regenerate a Sieve script from the `sieve' group parameters and
     put you into the `gnus-sieve-file' without saving it.

`D u'
     Regenerates the Gnus managed part of `gnus-sieve-file' using the
     `sieve' group parameters, save the file and upload it to the
     server using the `sieveshell' program.
\f
And a new texi file was added that document the Sieve package
separately from Gnus:

Sieve Support for Emacs
***********************

   This manual documents the Emacs Sieve package.

   It is intended as a users manual for Sieve Mode and Manage Sieve, and
as a reference manual for the `sieve-manage' protocol Emacs Lisp API.

   Sieve is a language for server-side filtering of mail.  The language
is documented in RFC 3028.  This manual does not attempt to document
the language, so keep RFC 3028 around.

* Menu:

* Installation::          Getting ready to use the package.
* Sieve Mode::            Editing Sieve scripts.
* Managing Sieve::        Managing Sieve scripts on a remote server.
* Manage Sieve API ::     Interfacing to the Manage Sieve Protocol API.
* Standards::             A summary of RFCs and working documents used.
* Index::                 Function and variable index.

Installation
************

   The Sieve package should come with your Emacs version, and should be
ready for use directly.

   However, to manually set up the package you can put the following
commands in your `~/.emacs':

     (autoload 'sieve-mode "sieve-mode")
     (setq auto-mode-alist (cons '("\\.si\\(v\\|eve\\)\\'" . sieve-mode)
                                 auto-mode-alist))

Sieve Mode
**********

   Sieve mode provides syntax-based indentation, font-locking support
and other handy functions to make editing Sieve scripts easier.

   Use `M-x sieve-mode' to switch to this major mode.  This command
runs the hook `sieve-mode-hook'.

   Sieve mode is derived from `c-mode', and is very similar except for
the syntax of comments.  The keymap (`sieve-mode-map') is inherited
from `c-mode', as are the the variables for customizing indentation.
Sieve mode has its own abbrev table (`sieve-mode-abbrev-table') and
syntax table (`sieve-mode-syntax-table').

   In addition to the editing utility functions, Sieve mode also
contains bindings to manage Sieve scripts remotely. *note Managing
Sieve::.

`C-c RET'
     Open a connection to a remote server using the Managesieve
     protocol.

`C-c C-l'
     Upload the Sieve script to the currently open server.

Managing Sieve
**************

   Manage Sieve is a special mode used to display Sieve scripts
available on a remote server.  It can be invoked with `M-x sieve-manage
RET', which queries the user for a server and if necessary, user
credentials to use.

   When a server has been succesfully contacted, the Manage Sieve buffer
looks something like:

     Server  : mailserver:2000
     
     2 scripts on server, press RET on a script name edits it, or
     press RET on <new script> to create a new script.
             <new script>
      ACTIVE .sieve
             template.siv

   One of the scripts are highlighted, and standard point navigation
commands (`<up>', `<down>' etc) can be used to navigate the list.

   The following commands are available in the Manage Sieve buffer:

`m'
     Activates the currently highlighted script.

`u'
     Deactivates the currently highlighted script.

`M-C-?'
     Deactivates all scripts.

`r'
     Remove currently highlighted script.

`RET'

`mouse-2'

`f'
     Bury the server buffer and download the currently highlighted
     script into a new buffer for editing in Sieve mode (*note Sieve
     Mode::).

`o'
     Create a new buffer in another window containing the currently
     highlighted script for editing in Sieve mode (*note Sieve Mode::).

`q'
     Bury the Manage Sieve buffer without closing the connection.

`?'

`h'
     Displays help in the minibuffer.

Manage Sieve API
****************

   The `sieve-manage.el' library contains low-level functionality for
talking to a server with the MANAGESIEVE protocol.

   A number of user-visible variables exist, which all can be customized
in the `sieve' group (`M-x customize-group RET sieve RET'):

`sieve-manage-default-user'
     Sets the default username.

`sieve-manage-default-port'
     Sets the default port to use, the suggested port number is `2000'.

`sieve-manage-log'
     If non-nil, should be a string naming a buffer where a protocol
     trace is dumped (for debugging purposes).

   The API functions include:

`sieve-manage-open'
     Open connection to managesieve server, returning a buffer to be
     used by all other API functions.

`sieve-manage-opened'
     Check if a server is open or not.

`sieve-manage-close'
     Close a server connection.

`sieve-manage-authenticate'
     Authenticate to the server.

`sieve-manage-capability'
     Return a list of capabilities the server support.

`sieve-manage-listscripts'
     List scripts on the server.

`sieve-manage-havespace'
     Returns non-nil iff server have roam for a script of given size.

`sieve-manage-getscript'
     Download script from server.

`sieve-manage-putscript'
     Upload script to server.

`sieve-manage-setactive'
     Indicate which script on the server should be active.

Standards
*********

   The Emacs Sieve package implements all or parts of a small but
hopefully growing number of RFCs and drafts documents.  This chapter
lists the relevant ones.  They can all be fetched from
`http://quimby.gnus.org/notes/'.

"RFC3028"
     Sieve: A Mail Filtering Language.

"draft-martin-managesieve-03"
     A Protocol for Remotely Managing Sieve Scripts





  parent reply	other threads:[~2001-11-01  0:53 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-10-21 13:01 Simon Josefsson
2001-10-21 14:02 ` Kai Großjohann
2001-10-22  1:21 ` Daniel Pittman
2001-11-01  0:53 ` Simon Josefsson [this message]
2001-11-01 16:08   ` Kai Großjohann
2001-11-01 16:50     ` Simon Josefsson
2001-11-02  8:25       ` Kai Großjohann
2001-11-02  8:50         ` Simon Josefsson
2001-11-02  9:14           ` Kai Großjohann
2001-11-02 12:39             ` Simon Josefsson
2001-11-02 16:24               ` Kai Großjohann
2001-11-02 17:52                 ` Amos Gouaux
2001-11-02 22:29                   ` Kai Großjohann
2001-11-04 14:49                     ` Steinar Bang
2001-11-04 17:35                       ` Amos Gouaux
2001-11-04 18:06                         ` Simon Josefsson
2001-11-04 18:44                           ` Amos Gouaux
2001-11-02 17:48         ` Amos Gouaux
2001-11-02 19:59           ` Simon Josefsson
2001-11-03  0:35       ` NAGY Andras
2001-11-03 18:58 ` possible gnus-sieve bug NAGY Andras
2001-11-03 19:06   ` Simon Josefsson
2001-11-04 13:17     ` NAGY Andras

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=iluady7tip6.fsf@dhcp128.extundo.com \
    --to=jas@extundo.com \
    /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).