@copying
Copyright (c) 1995, 1996, 1997, 1998, 1999, 2000, 2001,
-2002, 2003, 2004
+2002, 2003, 2004, 2005
Free Software Foundation, Inc.
@quotation
@end iftex
@menu
-* Starting Up:: Finding news can be a pain.
-* Group Buffer:: Selecting, subscribing and killing groups.
-* Summary Buffer:: Reading, saving and posting articles.
-* Article Buffer:: Displaying and handling articles.
-* Composing Messages:: Information on sending mail and news.
-* Select Methods:: Gnus reads all messages from various select methods.
-* Scoring:: Assigning values to articles.
-* Various:: General purpose settings.
-* The End:: Farewell and goodbye.
-* Appendices:: Terminology, Emacs intro, @acronym{FAQ}, History, Internals.
-* Index:: Variable, function and concept index.
-* Key Index:: Key Index.
+* Starting Up:: Finding news can be a pain.
+* Group Buffer:: Selecting, subscribing and killing groups.
+* Summary Buffer:: Reading, saving and posting articles.
+* Article Buffer:: Displaying and handling articles.
+* Composing Messages:: Information on sending mail and news.
+* Select Methods:: Gnus reads all messages from various select methods.
+* Scoring:: Assigning values to articles.
+* Various:: General purpose settings.
+* The End:: Farewell and goodbye.
+* Appendices:: Terminology, Emacs intro, @acronym{FAQ}, History, Internals.
+* Index:: Variable, function and concept index.
+* Key Index:: Key Index.
Other related manuals
-* Message:(message). Composing messages.
-* Emacs-MIME:(emacs-mime). Composing messages; @acronym{MIME}-specific parts.
-* Sieve:(sieve). Managing Sieve scripts in Emacs.
-* PGG:(pgg). @acronym{PGP/MIME} with Gnus.
-* SASL:(sasl). @acronym{SASL} authentication in Emacs.
+* Message:(message). Composing messages.
+* Emacs-MIME:(emacs-mime). Composing messages; @acronym{MIME}-specific parts.
+* Sieve:(sieve). Managing Sieve scripts in Emacs.
+* PGG:(pgg). @acronym{PGP/MIME} with Gnus.
+* SASL:(sasl). @acronym{SASL} authentication in Emacs.
@detailmenu
--- The Detailed Node Listing ---
* Direct Functions:: Connecting directly to the server.
* Indirect Functions:: Connecting indirectly to the server.
* Common Variables:: Understood by several connection functions.
+* NNTP marks:: Storing marks for @acronym{NNTP} servers.
Getting Mail
* Blackholes::
* Regular Expressions Header Matching::
* Bogofilter::
-* SpamAssassin backend::
+* SpamAssassin back end::
* ifile spam filtering::
* spam-stat spam filtering::
* SpamOracle::
terminology section (@pxref{Terminology}).
@menu
-* Finding the News:: Choosing a method for getting news.
-* The First Time:: What does Gnus do the first time you start it?
-* The Server is Down:: How can I read my mail then?
-* Slave Gnusae:: You can have more than one Gnus active at a time.
-* Fetching a Group:: Starting Gnus just to read a group.
-* New Groups:: What is Gnus supposed to do with new groups?
-* Changing Servers:: You may want to move from one server to another.
-* Startup Files:: Those pesky startup files---@file{.newsrc}.
-* Auto Save:: Recovering from a crash.
-* The Active File:: Reading the active file over a slow line Takes Time.
-* Startup Variables:: Other variables you might change.
+* Finding the News:: Choosing a method for getting news.
+* The First Time:: What does Gnus do the first time you start it?
+* The Server is Down:: How can I read my mail then?
+* Slave Gnusae:: You can have more than one Gnus active at a time.
+* New Groups:: What is Gnus supposed to do with new groups?
+* Changing Servers:: You may want to move from one server to another.
+* Startup Files:: Those pesky startup files---@file{.newsrc}.
+* Auto Save:: Recovering from a crash.
+* The Active File:: Reading the active file over a slow line Takes Time.
+* Startup Variables:: Other variables you might change.
@end menu
If you can use a local spool, you probably should, as it will almost
certainly be much faster. But do not use the local spool if your
-server is running Leafnode; in this case, use @code{(nntp "localhost")}.
+server is running Leafnode (which is a simple, standalone private news
+server); in this case, use @code{(nntp "localhost")}.
@vindex gnus-nntpserver-file
@cindex NNTPSERVER
(setq gnus-secondary-select-methods '((nnmbox "")))
@end lisp
+Note: the @acronym{NNTP} back end stores marks in marks files
+(@pxref{NNTP marks}). This feature makes it easy to share marks between
+several Gnus installations, but may slow down things a bit when fetching
+new articles. @xref{NNTP marks}, for more information.
+
@node The First Time
@section The First Time
@cindex first time usage
-If no startup files exist, gnus will try to determine what groups should
-be subscribed by default.
+If no startup files exist (@pxref{Startup Files}), gnus will try to
+determine what groups should be subscribed by default.
@vindex gnus-default-subscribed-newsgroups
If the variable @code{gnus-default-subscribed-newsgroups} is set, gnus
incorporated into the slave. If you answer ``no'', the slave may see some
messages as unread that have been read in the master.
-@node Fetching a Group
-@section Fetching a Group
-@cindex fetching a group
-
-@findex gnus-fetch-group
-It is sometimes convenient to be able to just say ``I want to read this
-group and I don't care whether gnus has been started or not''. This is
-perhaps more useful for people who write code than for users, but the
-command @code{gnus-fetch-group} provides this functionality in any case.
-It takes the group name as a parameter.
@node New Groups
@cindex .newsrc.el
@cindex .newsrc.eld
-Now, you all know about the @file{.newsrc} file. All subscription
-information is traditionally stored in this file.
+Most common Unix news readers use a shared startup file called
+@file{.newsrc}. This file contains all the information about what
+groups are subscribed, and which articles in these groups have been
+read.
Things got a bit more complicated with @sc{gnus}. In addition to
keeping the @file{.newsrc} file updated, it also used a file called
However, this will make it impossible to use other newsreaders than
gnus. But hey, who would want to, right? Similarly, setting
@code{gnus-read-newsrc-file} to @code{nil} makes gnus ignore the
-@file{.newsrc} file and any @file{.newsrc-SERVER} files, which is
-convenient if you have a tendency to use Netscape once in a while.
+@file{.newsrc} file and any @file{.newsrc-SERVER} files, which can be
+convenient if you use a different news reader occasionally, and you
+want to read a different subset of the available groups with that
+news reader.
@vindex gnus-save-killed-list
If @code{gnus-save-killed-list} (default @code{t}) is @code{nil}, Gnus
Commands}) the following Sieve code is generated:
@example
-if address \"sender\" \"sieve-admin@@extundo.com\" @{
- fileinto \"INBOX.list.sieve\";
+if address "sender" "sieve-admin@@extundo.com" @{
+ fileinto "INBOX.list.sieve";
@}
@end example
+To generate tests for multiple email-addresses use a group parameter
+like @code{(sieve address "sender" ("name@@one.org" else@@two.org"))}.
+When generating a sieve script (@pxref{Sieve Commands}) Sieve code
+like the following is generated:
+
+@example
+if address "sender" ["name@@one.org", "else@@two.org"] @{
+ fileinto "INBOX.list.sieve";
+@}
+@end example
+
+See @pxref{Sieve Commands} for commands and variables that might be of
+interest in relation to the sieve parameter.
+
The Sieve language is described in RFC 3028. @xref{Top, Emacs Sieve,
Top, sieve, Emacs Sieve}.
@item T M-p
@kindex T M-p (Topic)
@findex gnus-topic-goto-previous-topic
-Go to the next topic (@code{gnus-topic-goto-previous-topic}).
+Go to the previous topic (@code{gnus-topic-goto-previous-topic}).
@item G p
@kindex G p (Topic)
(@code{gnus-summary-limit-to-author}). If given a prefix, exclude
matching articles.
+@item / R
+@kindex / R (Summary)
+@findex gnus-summary-limit-to-recipient
+Limit the summary buffer to articles that match some recipient
+(@code{gnus-summary-limit-to-recipient}). If given a prefix, exclude
+matching articles.
+
@item / x
@kindex / x (Summary)
@findex gnus-summary-limit-to-extra
@findex gnus-thread-sort-by-score
@findex gnus-thread-sort-by-subject
@findex gnus-thread-sort-by-author
+@c @findex gnus-thread-sort-by-recipient
@findex gnus-thread-sort-by-number
@findex gnus-thread-sort-by-random
@vindex gnus-thread-sort-functions
@findex gnus-summary-morse-message
Morse decode the article buffer (@code{gnus-summary-morse-message}).
+@item W i
+@kindex W i (Summary)
+@findex gnus-summary-idna-message
+Decode IDNA encoded domain names in the current articles. IDNA
+encoded domain names looks like @samp{xn--bar}. If a string remain
+unencoded after running invoking this, it is likely an invalid IDNA
+string (@samp{xn--bar} is invalid). You must have GNU Libidn
+(@url{http://www.gnu.org/software/libidn/}) installed for this command
+to work.
+
@item W t
@item t
@kindex W t (Summary)
@code{mm-discouraged-alternatives} in @ref{Display Customization,
Display Customization, , emacs-mime, Emacs-Mime Manual}. Images or
other material inside a "multipart/related" part might be overlooked
-when this variable is nil.
+when this variable is @code{nil}.
@vindex gnus-mime-display-multipart-as-mixed
@item gnus-mime-display-multipart-as-mixed
-Display "multipart" parts as "multipart/mixed". If t, it overrides nil
-values of @code{gnus-mime-display-multipart-alternative-as-mixed} and
+Display "multipart" parts as "multipart/mixed". If @code{t}, it
+overrides @code{nil} values of
+@code{gnus-mime-display-multipart-alternative-as-mixed} and
@code{gnus-mime-display-multipart-related-as-mixed}.
@vindex mm-file-name-rewrite-functions
@findex gnus-summary-sort-by-author
Sort by author (@code{gnus-summary-sort-by-author}).
+@item C-c C-s C-t
+@kindex C-c C-s C-t (Summary)
+@findex gnus-summary-sort-by-recipient
+Sort by recipient (@code{gnus-summary-sort-by-recipient}).
+
@item C-c C-s C-s
@kindex C-c C-s C-s (Summary)
@findex gnus-summary-sort-by-subject
@item gnus-use-idna
This variable controls whether Gnus performs IDNA decoding of
internationalized domain names inside @samp{From}, @samp{To} and
-@samp{Cc} headers. This requires
+@samp{Cc} headers. @xref{IDNA, ,IDNA,message, The Message Manual},
+for how to compose such messages. This requires
@uref{http://www.gnu.org/software/libidn/, GNU Libidn}, and this
variable is only enabled if you have installed it.
* Direct Functions:: Connecting directly to the server.
* Indirect Functions:: Connecting indirectly to the server.
* Common Variables:: Understood by several connection functions.
+* NNTP marks:: Storing marks for @acronym{NNTP} servers.
@end menu
@end table
+@node NNTP marks
+@subsubsection NNTP marks
+@cindex storing NNTP marks
+
+Gnus stores marks (@pxref{Marking Articles}) for @acronym{NNTP}
+servers in marks files. A marks file records what marks you have set
+in a group and each file is specific to the corresponding server.
+Marks files are stored in @file{~/News/marks}
+(@code{nntp-marks-directory}) under a classic hierarchy resembling
+that of a news server, for example marks for the group
+@samp{gmane.discuss} on the news.gmane.org server will be stored in
+the file @file{~/News/marks/news.gmane.org/gmane/discuss/.marks}.
+
+Marks files are useful because you can copy the @file{~/News/marks}
+directory (using rsync, scp or whatever) to another Gnus installation,
+and it will realize what articles you have read and marked. The data
+in @file{~/News/marks} has priority over the same data in
+@file{~/.newsrc.eld}.
+
+Note that marks files are very much server-specific: Gnus remembers
+the article numbers so if you don't use the same servers on both
+installations things are most likely to break (most @acronym{NNTP}
+servers do not use the same article numbers as any other server).
+However, if you use servers A, B, C on one installation and servers A,
+D, E on the other, you can sync the marks files for A and then you'll
+get synchronization for that server between the two installations.
+
+Using @acronym{NNTP} marks can possibly incur a performance penalty so
+if Gnus feels sluggish, try setting the @code{nntp-marks-is-evil}
+variable to @code{t}. Marks will then be stored in @file{~/.newsrc.eld}.
+
+Related variables:
+
+@table @code
+
+@item nntp-marks-is-evil
+@vindex nntp-marks-is-evil
+If non-@code{nil}, this back end will ignore any marks files. The
+default is @code{nil}.
+
+@item nntp-marks-directory
+@vindex nntp-marks-directory
+The directory where marks for nntp groups will be stored.
+
+@end table
+
@node News Spool
@subsection News Spool
argument. It should return a non-@code{nil} value if it thinks that the
mail belongs in that group.
+@cindex @samp{bogus} group
The last of these groups should always be a general one, and the regular
-expression should @emph{always} be @samp{*} so that it matches any mails
+expression should @emph{always} be @samp{""} so that it matches any mails
that haven't been matched by any of the other regexps. (These rules are
-processed from the beginning of the alist toward the end. The first
-rule to make a match will ``win'', unless you have crossposting enabled.
-In that case, all matching rules will ``win''.) When new groups are
-created by splitting mail, you may want to run
-@code{gnus-group-find-new-groups} to see the new groups.
+processed from the beginning of the alist toward the end. The first rule
+to make a match will ``win'', unless you have crossposting enabled. In
+that case, all matching rules will ``win''.) If no rule matched, the mail
+will end up in the @samp{bogus} group. When new groups are created by
+splitting mail, you may want to run @code{gnus-group-find-new-groups} to
+see the new groups. This also applies to the @samp{bogus} group.
If you like to tinker with this yourself, you can set this variable to a
function of your choice. This function will be called without any
The mail back ends all support cross-posting. If several regexps match,
the mail will be ``cross-posted'' to all those groups.
@code{nnmail-crosspost} says whether to use this mechanism or not. Note
-that no articles are crossposted to the general (@samp{*}) group.
+that no articles are crossposted to the general (@samp{""}) group.
@vindex nnmail-crosspost-link-function
@cindex crosspost
The buffer is narrowed to the message in question when @var{function}
is run. That's why @code{(widen)} needs to be called after
@code{save-excursion} and @code{save-restriction} in the example
-above. Also note that with the nnimap backend, message bodies will
+above. Also note that with the nnimap back end, message bodies will
not be downloaded by default. You need to set
@code{nnimap-split-download-body} to @code{t} to do that
(@pxref{Splitting in IMAP}).
@acronym{RSS} has a quite regular and nice interface, and it's
possible to get the information Gnus needs to keep groups updated.
+Note: you had better use Emacs which supports the @code{utf-8} coding
+system because @acronym{RSS} uses UTF-8 for encoding non-@acronym{ASCII}
+text by default. It is also used by default for non-@acronym{ASCII}
+group names.
+
@kindex G R (Summary)
-Use @kbd{G R} from the summary buffer to subscribe to a feed---you
-will be prompted for the location of the feed.
+Use @kbd{G R} from the summary buffer to subscribe to a feed---you will
+be prompted for the location, the title and the description of the feed.
+The title, which allows any characters, will be used for the group name
+and the name of the group data file. The description can be omitted.
An easy way to get started with @code{nnrss} is to say something like
-the following in the group buffer: @kbd{B nnrss RET y}, then
+the following in the group buffer: @kbd{B nnrss RET RET y}, then
subscribe to groups.
+The @code{nnrss} back end saves the group data file in
+@code{nnrss-directory} (see below) for each @code{nnrss} group. File
+names containing non-@acronym{ASCII} characters will be encoded by the
+coding system specified with the @code{nnmail-pathname-coding-system}
+variable. If it is @code{nil}, in Emacs the coding system defaults to
+the value of @code{default-file-name-coding-system}. If you are using
+XEmacs and want to use non-@acronym{ASCII} group names, you should set
+the value for the @code{nnmail-pathname-coding-system} variable properly.
+
@cindex OPML
You can also use the following commands to import and export your
subscriptions from a file in @acronym{OPML} format (Outline Processor
The directory where @code{nnrss} stores its files. The default is
@file{~/News/rss/}.
+@item nnrss-file-coding-system
+@vindex nnrss-file-coding-system
+The coding system used when reading and writing the @code{nnrss} groups
+data files. The default is the value of
+@code{mm-universal-coding-system} (which defaults to @code{emacs-mule}
+in Emacs or @code{escape-quoted} in XEmacs).
+
@item nnrss-use-local
@vindex nnrss-use-local
@findex nnrss-generate-download-script
@vindex gnus-agent
Is the agent enabled? The default is @code{t}. When first enabled,
the agent will use @code{gnus-agent-auto-agentize-methods} to
-automatically mark some backends as agentized. You may change which
-backends are agentized using the agent commands in the server buffer.
+automatically mark some back ends as agentized. You may change which
+back ends are agentized using the agent commands in the server buffer.
To enter the server buffer, use the @kbd{^}
(@code{gnus-group-enter-server-mode}) command in the group buffer.
If you have never used the Agent before (or more technically, if
@file{~/News/agent/lib/servers} does not exist), Gnus will
automatically agentize a few servers for you. This variable control
-which backends should be auto-agentized. It is typically only useful
-to agentize remote backends. The auto-agentizing has the same effect
+which back ends should be auto-agentized. It is typically only useful
+to agentize remote back ends. The auto-agentizing has the same effect
as running @kbd{J a} on the servers (@pxref{Server Agent Commands}).
If the file exist, you must manage the servers manually by adding or
removing them, this variable is only applicable the first time you
When score files are loaded and @code{gnus-decay-scores} is
non-@code{nil}, Gnus will run the score files through the decaying
mechanism thereby lowering the scores of all non-permanent score rules.
-The decay itself if performed by the @code{gnus-decay-score-function}
-function, which is @code{gnus-decay-score} by default. Here's the
-definition of that function:
+If @code{gnus-decay-scores} is a regexp, only score files matching this
+regexp are treated. E.g. you may set it to @samp{\\.ADAPT\\'} if only
+@emph{adaptive} score files should be decayed. The decay itself if
+performed by the @code{gnus-decay-score-function} function, which is
+@code{gnus-decay-score} by default. Here's the definition of that
+function:
@lisp
(defun gnus-decay-score (score)
* Undo:: Some actions can be undone.
* Predicate Specifiers:: Specifying predicates.
* Moderation:: What to do if you're a moderator.
+* Fetching a Group:: Starting Gnus just to read a group.
* Image Enhancements:: Modern versions of Emacs/XEmacs can display images.
* Fuzzy Matching:: What's the big fuzz?
* Thwarting Email Spam:: A how-to on avoiding unsolicited commercial email.
@end lisp
+@node Fetching a Group
+@section Fetching a Group
+@cindex fetching a group
+
+@findex gnus-fetch-group
+It is sometimes convenient to be able to just say ``I want to read this
+group and I don't care whether Gnus has been started or not''. This is
+perhaps more useful for people who write code than for users, but the
+command @code{gnus-fetch-group} provides this functionality in any case.
+It takes the group name as a parameter.
+
+
@node Image Enhancements
@section Image Enhancements
@code{gnus-picon-databases} points to the directory containing the
Picons databases.
+@vindex gnus-picon-style
+The variable @code{gnus-picon-style} controls how picons are displayed.
+If @code{inline}, the textual representation is replaced. If
+@code{right}, picons are added right to the textual representation.
+
The following variables offer control over where things are located.
@table @code
"spam"))))
@end lisp
-Note that with the nnimap backend, message bodies will not be
+Note that with the nnimap back end, message bodies will not be
downloaded by default. You need to set
@code{nnimap-split-download-body} to @code{t} to do that
(@pxref{Splitting in IMAP}).
@item hashcash-default-payment
@vindex hashcash-default-payment
This variable indicates the default number of bits the hash collision
-should consist of. By default this is 10, which is a rather low
-value. Suggested useful values include 17 to 29.
+should consist of. By default this is 20. Suggested useful values
+include 17 to 29.
@item hashcash-payment-alist
@vindex hashcash-payment-alist
@item hashcash-path
@vindex hashcash-path
Where the @code{hashcash} binary is installed. This variable should
-be automatically set by @code{executable-find}, but if it's nil
+be automatically set by @code{executable-find}, but if it's @code{nil}
(usually because the @code{hashcash} binary is not in your path)
you'll get a warning when you check hashcash payments and an error
when you generate hashcash payments.
hand customized mail filtering scripts. To verify a hashcash cookie
in a message, use the @code{mail-check-payment} function in the
@code{hashcash.el} library. You can also use the @code{spam.el}
-package with the @code{spam-use-hashcash} backend to validate hashcash
+package with the @code{spam-use-hashcash} back end to validate hashcash
cookies in incoming mail and filter mail accordingly (@pxref{Anti-spam
Hashcash Payments}).
@cindex spam filtering
@cindex spam
-The idea behind @file{spam.el} is to have a control center for spam detection
-and filtering in Gnus. To that end, @file{spam.el} does two things: it
+The idea behind @code{spam.el} is to have a control center for spam detection
+and filtering in Gnus. To that end, @code{spam.el} does two things: it
filters new mail, and it analyzes mail known to be spam or ham.
-@dfn{Ham} is the name used throughout @file{spam.el} to indicate
+@dfn{Ham} is the name used throughout @code{spam.el} to indicate
non-spam messages.
-First of all, you @strong{must} run the function
-@code{spam-initialize} to autoload @code{spam.el} and to install the
+Make sure you read the section on the @code{spam.el} sequence of
+events. See @xref{Spam ELisp Package Sequence of Events}.
+
+@cindex spam-initialize
+To use @code{spam.el}, you @strong{must} run the function
+@code{spam-initialize} to autoload @file{spam.el} and to install the
@code{spam.el} hooks. There is one exception: if you use the
@code{spam-use-stat} (@pxref{spam-stat spam filtering}) setting, you
should turn it on before @code{spam-initialize}:
* Spam ELisp Package Sequence of Events::
* Spam ELisp Package Filtering of Incoming Mail::
* Spam ELisp Package Global Variables::
+* Spam ELisp Package Sorting and Score Display in Summary Buffer::
* Spam ELisp Package Configuration Examples::
* Blacklists and Whitelists::
* BBDB Whitelists::
* Blackholes::
* Regular Expressions Header Matching::
* Bogofilter::
-* SpamAssassin backend::
+* SpamAssassin back end::
* ifile spam filtering::
* spam-stat spam filtering::
* SpamOracle::
@cindex spam filtering
@cindex spam filtering sequence of events
@cindex spam
-
You must read this section to understand how @code{spam.el} works.
Do not skip, speed-read, or glance through this section.
@code{spam.el} and the rest of Gnus: checking new mail for spam, and
leaving a group.
-Getting new mail is done in one of two ways. You can either split
-your incoming mail or you can classify new articles as ham or spam
-when you enter the group.
+Getting new mail in Gnus is done in one of two ways. You can either
+split your incoming mail or you can classify new articles as ham or
+spam when you enter the group.
-Splitting incoming mail is better suited to mail backends such as
+Splitting incoming mail is better suited to mail back ends such as
@code{nnml} or @code{nnimap} where new mail appears in a single file
called a @dfn{Spool File}. See @xref{Spam ELisp Package Filtering of
Incoming Mail}.
@vindex gnus-spam-autodetect
@vindex gnus-spam-autodetect-methods
-For backends such as @code{nntp} there is no incoming mail spool, so
+For back ends such as @code{nntp} there is no incoming mail spool, so
an alternate mechanism must be used. This may also happen for
-backends where the server is in charge of splitting incoming mail, and
+back ends where the server is in charge of splitting incoming mail, and
Gnus does not do further splitting. The @code{spam-autodetect} and
@code{spam-autodetect-methods} group parameters (accessible with
@kbd{G c} and @kbd{G p} as usual), and the corresponding variables
(accessible with @kbd{M-x customize-variable} as usual) can help.
When @code{spam-autodetect} is used (you can turn it on for a
-group/topic or wholesale by regex, as needed), it hooks into the
-process of entering a group. Thus, entering a group with unseen or
-unread articles becomes the substitute for checking incoming mail.
-Whether only unseen articles or all unread articles will be processed
-is determined by the @code{spam-autodetect-recheck-messages}. When
-set to @code{t}, unread messages will be rechecked.
+group/topic or wholesale by regular expression matches, as needed), it
+hooks into the process of entering a group. Thus, entering a group
+with unseen or unread articles becomes the substitute for checking
+incoming mail. Whether only unseen articles or all unread articles
+will be processed is determined by the
+@code{spam-autodetect-recheck-messages}. When set to @code{t}, unread
+messages will be rechecked. You should probably stick with the
+default of only checking unseen messages.
@code{spam-autodetect} grants the user at once more and less control
of spam filtering. The user will have more control over each group's
variable) will be marked as spam. Thus, mail split into a spam group
gets automatically marked as spam when you enter the group.
-So, when you exit a group, the @code{spam-processors} are applied, if
-any are set, and the processed mail is moved to the
+Thus, when you exit a group, the @code{spam-processors} are applied,
+if any are set, and the processed mail is moved to the
@code{ham-process-destination} or the @code{spam-process-destination}
depending on the article's classification. If the
@code{ham-process-destination} or the @code{spam-process-destination},
@code{spam-process-destination} is @code{nil}, the spam is marked as
expired, which is usually the right thing to do.
-If spam can not be moved---because of a read-only backend such as
+If spam can not be moved---because of a read-only back end such as
@acronym{NNTP}, for example, it will be copied.
If a ham mail is found in a ham group, as determined by the
necessary, which is what most people want. More on this in
@xref{Spam ELisp Package Configuration Examples}.
-If ham can not be moved---because of a read-only backend such as
+If ham can not be moved---because of a read-only back end such as
@acronym{NNTP}, for example, it will be copied.
If all this seems confusing, don't worry. Soon it will be as natural
@cindex spam filtering incoming mail
@cindex spam
-To use the @file{spam.el} facilities for incoming mail filtering, you
+To use the @code{spam.el} facilities for incoming mail filtering, you
must add the following to your fancy split list
@code{nnmail-split-fancy} or @code{nnimap-split-fancy}:
The boolean variable @code{nnimap-split-download-body} needs to be
set, if you want to split based on the whole message instead of just
the headers. By default, the nnimap back end will only retrieve the
-message headers. If you use @code{spam-check-bogofilter},
-@code{spam-check-ifile}, or @code{spam-check-stat} (the splitters that
-can benefit from the full message body), you should set this variable.
-It is not set by default because it will slow @acronym{IMAP} down, and
-that is not an appropriate decision to make on behalf of the user.
+message headers. If you use a @emph{statistical} filter,
+e.g. @code{spam-check-bogofilter}, @code{spam-check-ifile}, or
+@code{spam-check-stat} (the splitters that can benefit from the full
+message body), this variable will be set automatically. It is not set
+for non-statistical back ends by default because it will slow
+@acronym{IMAP} down.
@xref{Splitting in IMAP}.
-@emph{TODO: spam.el needs to provide a uniform way of training all the
-statistical databases. Some have that functionality built-in, others
-don't.}
-
@node Spam ELisp Package Global Variables
@subsubsection Spam ELisp Package Global Variables
@cindex spam filtering
@code{spam-mark-ham-unread-before-move-from-spam-group} parameter is
set, the ham articles are marked as unread before being moved.
-If ham can not be moved---because of a read-only backend such as
+If ham can not be moved---because of a read-only back end such as
@acronym{NNTP}, for example, it will be copied.
Note that you can use multiples destinations per group or regular
that if you see @samp{nntp:servername} before the group name in the
group buffer then you need it here as well.
-If spam can not be moved---because of a read-only backend such as
+If spam can not be moved---because of a read-only back end such as
@acronym{NNTP}, for example, it will be copied.
Note that you can use multiples destinations per group or regular
only unseen articles or all unread articles should be checked for
spam. It is recommended that you leave it off.
+@node Spam ELisp Package Sorting and Score Display in Summary Buffer
+@subsubsection Spam ELisp Package Sorting and Score Display in Summary Buffer
+@cindex spam scoring
+@cindex spam sorting
+@cindex spam score summary buffer
+@cindex spam sort summary buffer
+@cindex spam
+
+You can display the spam score of articles in your summary buffer, and
+you can sort articles by their spam score.
+
+First you need to decide which back end you will be using. If you use
+the @code{spam-use-spamassassin},
+@code{spam-use-spamassassin-headers}, or @code{spam-use-regex-headers}
+back end, the @code{X-Spam-Status} header will be used. If you use
+@code{spam-use-bogofilter}, the @code{X-Bogosity} header will be used.
+If you use @code{spam-use-crm114}, any header that matches the CRM114
+score format will be used. As long as you set the appropriate back end
+variable to t @emph{before} you load @file{spam.el}, you will be
+fine. @code{spam.el} will automatically add the right header to the
+internal Gnus list of required headers.
+
+To show the spam score in your summary buffer, add this line to your
+@code{gnus.el} file (note @code{spam.el} does not do that by default
+so it won't override any existing @code{S} formats you may have).
+
+@lisp
+(defalias 'gnus-user-format-function-S 'spam-user-format-function-S)
+@end lisp
+
+Now just set your summary line format to use @code{%uS}. Here's an
+example that formats the spam score in a 5-character field:
+
+@lisp
+(setq gnus-summary-line-format
+ "%U%R %10&user-date; $%5uS %6k %B %(%4L: %*%-25,25a%) %s \n")
+@end lisp
+
+Finally, to sort by spam status, either do it globally:
+
+@lisp
+(setq
+ gnus-show-threads nil
+ gnus-article-sort-functions
+ '(spam-article-sort-by-spam-status))
+@end lisp
+
+or per group (@pxref{Sorting the Summary Buffer}).
+
@node Spam ELisp Package Configuration Examples
@subsubsection Spam ELisp Package Configuration Examples
@cindex spam filtering
@end example
-@subsubheading Using @file{spam.el} on an IMAP server with a statistical filter on the server
+@subsubheading Using @code{spam.el} on an IMAP server with a statistical filter on the server
From Reiner Steib <reiner.steib@@gmx.de>.
My provider has set up bogofilter (in combination with @acronym{DCC}) on
In my ham folders, I just hit @kbd{S x}
(@code{gnus-summary-mark-as-spam}) whenever I see an unrecognized spam
mail (false negative). On group exit, those messages are moved to
-@samp{training.ham}.
+@samp{training.spam}.
@end itemize
@subsubheading Reporting spam articles in Gmane groups with @code{spam-report.el}
addresses in the BBDB will be allowed through; all others will be
classified as spammers.
+While @code{spam-use-BBDB-exclusive} @emph{can} be used as an alias
+for @code{spam-use-BBDB} as far as @code{spam.el} is concerned, it is
+@emph{not} a separate back end. If you set
+@code{spam-use-BBDB-exclusive} to t, @emph{all} your BBDB splitting
+will be exclusive.
+
@end defvar
@defvar gnus-group-ham-exit-processor-BBDB
contains outdated servers.
The blackhole check uses the @code{dig.el} package, but you can tell
-@file{spam.el} to use @code{dns.el} instead for better performance if
+@code{spam.el} to use @code{dns.el} instead for better performance if
you set @code{spam-use-dig} to @code{nil}. It is not recommended at
this time to set @code{spam-use-dig} to @code{nil} despite the
possible performance improvements, because some users may be unable to
used, or has already been used on the article. The 0.9.2.1 version of
Bogofilter was used to test this functionality.
-@node SpamAssassin backend
-@subsubsection SpamAssassin backend
+@node SpamAssassin back end
+@subsubsection SpamAssassin back end
@cindex spam filtering
@cindex spamassassin, spam filtering
@cindex spam
the same way, we promise.
@end defvar
-This enables @file{spam.el} to cooperate with @file{spam-stat.el}.
+This enables @code{spam.el} to cooperate with @file{spam-stat.el}.
@file{spam-stat.el} provides an internal (Lisp-only) spam database,
which unlike ifile or Bogofilter does not require external programs.
A spam and a ham processor, and the @code{spam-use-stat} variable for
@xref{Mail Source Specifiers}, (@pxref{SpamAssassin}). This method has
the advantage that the user can see the @emph{X-Spam} headers.
-The easiest method is to make @file{spam.el} (@pxref{Filtering Spam
+The easiest method is to make @code{spam.el} (@pxref{Filtering Spam
Using The Spam ELisp Package}) call SpamOracle.
@vindex spam-use-spamoracle
-To enable SpamOracle usage by @file{spam.el}, set the variable
+To enable SpamOracle usage by @code{spam.el}, set the variable
@code{spam-use-spamoracle} to @code{t} and configure the
@code{nnmail-split-fancy} or @code{nnimap-split-fancy} as described in
the section @xref{Filtering Spam Using The Spam ELisp Package}. In
characteristics of your spam mails. Using the @emph{add} mode
(training mode) one has to feed good (ham) and spam mails to
SpamOracle. This can be done by pressing @kbd{|} in the Summary buffer
-and pipe the mail to a SpamOracle process or using @file{spam.el}'s
+and pipe the mail to a SpamOracle process or using @code{spam.el}'s
spam- and ham-processors, which is much more convenient. For a
detailed description of spam- and ham-processors, @xref{Filtering Spam
Using The Spam ELisp Package}.
"True if blackbox should be used.")
@end lisp
-Add
-@lisp
-(spam-use-blackbox . spam-check-blackbox)
-@end lisp
-to @code{spam-list-of-checks}.
+Write @code{spam-check-blackbox} if Blackbox can check incoming mail.
-Add
-@lisp
-(gnus-group-ham-exit-processor-blackbox ham spam-use-blackbox)
-(gnus-group-spam-exit-processor-blackbox spam spam-use-blackbox)
-@end lisp
-
-to @code{spam-list-of-processors}.
-
-Add
-@lisp
-(spam-use-blackbox spam-blackbox-register-routine
- nil
- spam-blackbox-unregister-routine
- nil)
-@end lisp
-
-to @code{spam-registration-functions}. Write the register/unregister
-routines using the bogofilter register/unregister routines as a
-start, or other restister/unregister routines more appropriate to
-Blackbox.
+Write @code{spam-blackbox-register-routine} and
+@code{spam-blackbox-unregister-routine} using the bogofilter
+register/unregister routines as a start, or other restister/unregister
+routines more appropriate to Blackbox, if Blackbox can
+register/unregister spam and ham.
@item
Functionality
-Write the @code{spam-check-blackbox} function. It should return
-@samp{nil} or @code{spam-split-group}, observing the other
-conventions. See the existing @code{spam-check-*} functions for
-examples of what you can do, and stick to the template unless you
-fully understand the reasons why you aren't.
-
-Make sure to add @code{spam-use-blackbox} to
-@code{spam-list-of-statistical-checks} if Blackbox is a statistical
-mail analyzer that needs the full message body to operate.
+The @code{spam-check-blackbox} function should return @samp{nil} or
+@code{spam-split-group}, observing the other conventions. See the
+existing @code{spam-check-*} functions for examples of what you can
+do, and stick to the template unless you fully understand the reasons
+why you aren't.
@end enumerate
(variable-item spam-use-blackbox)
@end lisp
to the @code{spam-autodetect-methods} group parameter in
-@code{gnus.el}.
+@code{gnus.el} if Blackbox can check incoming mail for spam contents.
+
+Finally, use the appropriate @code{spam-install-*-backend} function in
+@code{spam.el}. Here are the available functions.
+
+
+@enumerate
+
+@item
+@code{spam-install-backend-alias}
+
+This function will simply install an alias for a back end that does
+everything like the original back end. It is currently only used to
+make @code{spam-use-BBDB-exclusive} act like @code{spam-use-BBDB}.
+
+@item
+@code{spam-install-nocheck-backend}
+
+This function installs a back end that has no check function, but can
+register/unregister ham or spam. The @code{spam-use-gmane} back end is
+such a back end.
+
+@item
+@code{spam-install-checkonly-backend}
+
+This function will install a back end that can only check incoming mail
+for spam contents. It can't register or unregister messages.
+@code{spam-use-blackholes} and @code{spam-use-hashcash} are such
+back ends.
+
+@item
+@code{spam-install-statistical-checkonly-backend}
+
+This function installs a statistical back end (one which requires the
+full body of a message to check it) that can only check incoming mail
+for contents. @code{spam-use-regex-body} is such a filter.
+
+@item
+@code{spam-install-statistical-backend}
+
+This function install a statistical back end with incoming checks and
+registration/unregistration routines. @code{spam-use-bogofilter} is
+set up this way.
+
+@item
+@code{spam-install-backend}
+
+This is the most normal back end installation, where a back end that can
+check and register/unregister messages is set up without statistical
+abilities. The @code{spam-use-BBDB} is such a back end.
+
+@item
+@code{spam-install-mover-backend}
+
+Mover back ends are internal to @code{spam.el} and specifically move
+articles around when the summary is exited. You will very probably
+never install such a back end.
+@end enumerate
@end enumerate
number of unread articles is called @dfn{activating the group}.
Un-activated groups are listed with @samp{*} in the group buffer.
+@item spool
+@cindex spool
+News servers store their articles locally in one fashion or other.
+One old-fashioned storage method is to have just one file per
+article. That's called a ``traditional spool''.
+
@item server
@cindex server
A machine one can connect to and get news (or mail) from.
alterations. This comes in handy if the back end really carries all
the information (as is the case with virtual and imap groups). This
function should destructively alter the info to suit its needs, and
-should return a non-@code{nil} value.
+should return a non-@code{nil} value (exceptionally,
+@code{nntp-request-update-info} always returns @code{nil} not to waste
+the network resources).
There should be no result data from this function.