From: yamaoka Date: Wed, 15 Jan 2003 22:37:34 +0000 (+0000) Subject: Synch with Oort Gnus. X-Git-Tag: t-gnus-6_15_14-00-quimby~27 X-Git-Url: http://git.chise.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=af0597dc03359be163d7dfb3c495c6eab317f63b;p=elisp%2Fgnus.git- Synch with Oort Gnus. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 2ff7e30..5ecde6d 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,31 @@ +2003-01-15 Jesper Harder + + * gnus-xmas.el (gnus-xmas-redefine): Use region-exists-p in + XEmacs. + + * gnus-ems.el (gnus-mark-active-p): do. + +2003-01-15 Kevin Ryde + + * gnus.texi (Using MIME): Mention auto-compression-mode with + gnus-mime-copy-part. + +2003-01-15 Lars Magne Ingebrigtsen + + * message.el (message-send): Don't warn about duplicates when + superseding. + +2003-01-15 Simon Josefsson + + * nnimap.el (nnimap-split-download-body): New variable. + (nnimap-split-articles): Use it. + +2003-01-15 Teodor Zlatanov + + * gnus.el (gnus-install-group-spam-parameters): new variable, t by + default, in the gnus-start customization group. Used to disable + the spam-*/ham-* parameters. + 2002-01-14 Kevin Greiner * gnus-agent.el (gnus-agent-check-overview-buffer): This data diff --git a/lisp/gnus-art.el b/lisp/gnus-art.el index e06b0cb..fe57616 100644 --- a/lisp/gnus-art.el +++ b/lisp/gnus-art.el @@ -4358,7 +4358,9 @@ The uncompress method used is derived from `buffer-file-name'." (jka-compr-delete-temp-file err-file))))))) (defun gnus-mime-copy-part (&optional handle) - "Put the MIME part under point into a new buffer." + "Put the MIME part under point into a new buffer. +If `auto-compression-mode' is enabled, compressed files like .gz and .bz2 +are decompressed." (interactive) (gnus-article-check-buffer) (let* ((handle (or handle (get-text-property (point) 'gnus-data))) diff --git a/lisp/gnus-ems.el b/lisp/gnus-ems.el index a81d7a5..b470b3f 100644 --- a/lisp/gnus-ems.el +++ b/lisp/gnus-ems.el @@ -162,10 +162,8 @@ mark-active)) (defun gnus-mark-active-p () -"Non-nil means the mark and region are currently active in this buffer." - (if (boundp 'mark-active) - mark-active ; Emacs - (mark))) ; XEmacs + "Non-nil means the mark and region are currently active in this buffer." + mark-active) ; aliased to region-exists-p in XEmacs. (if (fboundp 'add-minor-mode) (defalias 'gnus-add-minor-mode 'add-minor-mode) diff --git a/lisp/gnus-xmas.el b/lisp/gnus-xmas.el index 79f1064..418e68e 100644 --- a/lisp/gnus-xmas.el +++ b/lisp/gnus-xmas.el @@ -1,6 +1,6 @@ ;;; gnus-xmas.el --- Gnus functions for XEmacs -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002 +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003 ;; Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen @@ -434,6 +434,7 @@ call it with the value of the `gnus-data' text property." 'gnus-xmas-mode-line-buffer-identification) (defalias 'gnus-key-press-event-p 'key-press-event-p) (defalias 'gnus-region-active-p 'region-active-p) + (defalias 'gnus-mark-active-p 'region-exists-p) (defalias 'gnus-annotation-in-region-p 'gnus-xmas-annotation-in-region-p) (defalias 'gnus-mime-button-menu 'gnus-xmas-mime-button-menu) (defalias 'gnus-image-type-available-p 'gnus-xmas-image-type-available-p) diff --git a/lisp/gnus.el b/lisp/gnus.el index fc8698a..f88f059 100644 --- a/lisp/gnus.el +++ b/lisp/gnus.el @@ -1779,181 +1779,188 @@ articles to list when the group is a large newsgroup (see total number of articles in the group.") ;; group parameters for spam processing added by Ted Zlatanov -(defvar gnus-group-spam-classification-spam t - "Spam group classification (requires spam.el). +(defcustom gnus-install-group-spam-parameters t + "*Disable the group parameters for spam detection. +Enable if `G c' in XEmacs is giving you trouble, and make sure to submit a bug report." + :type 'boolean + :group 'gnus-start) + +(when gnus-install-group-spam-parameters + (defvar gnus-group-spam-classification-spam t + "Spam group classification (requires spam.el). This group contains spam messages. On summary entry, unread messages will be marked as spam. On summary exit, the specified spam processors will be invoked on spam-marked messages, then those messages will be expired, so the spam processor will only see a spam-marked message once.") -(defvar gnus-group-spam-classification-ham 'ask - "The ham value for the spam group parameter (requires spam.el). + (defvar gnus-group-spam-classification-ham 'ask + "The ham value for the spam group parameter (requires spam.el). On summary exit, the specified ham processors will be invoked on ham-marked messages. Exercise caution, since the ham processor will see the same message more than once because there is no ham message registry.") -(gnus-define-group-parameter - spam-contents - :type list - :function-document - "The spam type (spam, ham, or neither) of the group." - :variable gnus-spam-newsgroup-contents - :variable-default nil - :variable-document - "*Groups in which to automatically mark new articles as spam on + (gnus-define-group-parameter + spam-contents + :type list + :function-document + "The spam type (spam, ham, or neither) of the group." + :variable gnus-spam-newsgroup-contents + :variable-default nil + :variable-document + "*Groups in which to automatically mark new articles as spam on summary entry. If non-nil, this should be a list of group name regexps that should match all groups in which to do automatic spam tagging, associated with a classification (spam, ham, or neither). This only makes sense for mail groups." - :variable-group spam - :variable-type '(repeat - (list :tag "Group contents spam/ham classification" + :variable-group spam + :variable-type '(repeat + (list :tag "Group contents spam/ham classification" (regexp :tag "Group") (choice (variable-item gnus-group-spam-classification-spam) (variable-item gnus-group-spam-classification-ham) (other :tag "Unclassified" nil)))) - :parameter-type '(list :tag "Group contents spam/ham classification" - (choice :tag "Group contents classification for spam sorting" - (variable-item gnus-group-spam-classification-spam) - (variable-item gnus-group-spam-classification-ham) - (other :tag "Unclassified" nil))) - :parameter-document - "The spam classification (spam, ham, or neither) of this group. + :parameter-type '(list :tag "Group contents spam/ham classification" + (choice :tag "Group contents classification for spam sorting" + (variable-item gnus-group-spam-classification-spam) + (variable-item gnus-group-spam-classification-ham) + (other :tag "Unclassified" nil))) + :parameter-document + "The spam classification (spam, ham, or neither) of this group. When a spam group is entered, all unread articles are marked as spam.") -(defvar gnus-group-spam-exit-processor-ifile "ifile" - "The ifile summary exit spam processor. + (defvar gnus-group-spam-exit-processor-ifile "ifile" + "The ifile summary exit spam processor. Only applicable to spam groups.") -(defvar gnus-group-spam-exit-processor-stat "stat" - "The spam-stat summary exit spam processor. + (defvar gnus-group-spam-exit-processor-stat "stat" + "The spam-stat summary exit spam processor. Only applicable to spam groups.") -(defvar gnus-group-spam-exit-processor-bogofilter "bogofilter" - "The Bogofilter summary exit spam processor. + (defvar gnus-group-spam-exit-processor-bogofilter "bogofilter" + "The Bogofilter summary exit spam processor. Only applicable to spam groups.") -(defvar gnus-group-spam-exit-processor-blacklist "blacklist" - "The Blacklist summary exit spam processor. + (defvar gnus-group-spam-exit-processor-blacklist "blacklist" + "The Blacklist summary exit spam processor. Only applicable to spam groups.") -(defvar gnus-group-ham-exit-processor-ifile "ifile-ham" - "The ifile summary exit ham processor. + (defvar gnus-group-ham-exit-processor-ifile "ifile-ham" + "The ifile summary exit ham processor. Only applicable to non-spam (unclassified and ham) groups.") -(defvar gnus-group-ham-exit-processor-stat "stat-ham" - "The spam-stat summary exit ham processor. + (defvar gnus-group-ham-exit-processor-stat "stat-ham" + "The spam-stat summary exit ham processor. Only applicable to non-spam (unclassified and ham) groups.") -(defvar gnus-group-ham-exit-processor-whitelist "whitelist" - "The whitelist summary exit ham processor. + (defvar gnus-group-ham-exit-processor-whitelist "whitelist" + "The whitelist summary exit ham processor. Only applicable to non-spam (unclassified and ham) groups.") -(defvar gnus-group-ham-exit-processor-BBDB "bbdb" - "The BBDB summary exit ham processor. + (defvar gnus-group-ham-exit-processor-BBDB "bbdb" + "The BBDB summary exit ham processor. Only applicable to non-spam (unclassified and ham) groups.") -(gnus-define-group-parameter - spam-process - :type list - :parameter-type '(choice :tag "Spam Summary Exit Processor" - :value nil - (list :tag "Spam Summary Exit Processor Choices" - (set - (variable-item gnus-group-spam-exit-processor-ifile) - (variable-item gnus-group-spam-exit-processor-stat) - (variable-item gnus-group-spam-exit-processor-bogofilter) - (variable-item gnus-group-spam-exit-processor-blacklist) - (variable-item gnus-group-ham-exit-processor-ifile) - (variable-item gnus-group-ham-exit-processor-stat) - (variable-item gnus-group-ham-exit-processor-whitelist) - (variable-item gnus-group-ham-exit-processor-BBDB)))) - :function-document - "Which spam or ham processors will be applied to the GROUP articles at summary exit." - :variable gnus-spam-process-newsgroups - :variable-default nil - :variable-document - "*Groups in which to automatically process spam or ham articles with + (gnus-define-group-parameter + spam-process + :type list + :parameter-type '(choice :tag "Spam Summary Exit Processor" + :value nil + (list :tag "Spam Summary Exit Processor Choices" + (set + (variable-item gnus-group-spam-exit-processor-ifile) + (variable-item gnus-group-spam-exit-processor-stat) + (variable-item gnus-group-spam-exit-processor-bogofilter) + (variable-item gnus-group-spam-exit-processor-blacklist) + (variable-item gnus-group-ham-exit-processor-ifile) + (variable-item gnus-group-ham-exit-processor-stat) + (variable-item gnus-group-ham-exit-processor-whitelist) + (variable-item gnus-group-ham-exit-processor-BBDB)))) + :function-document + "Which spam or ham processors will be applied to the GROUP articles at summary exit." + :variable gnus-spam-process-newsgroups + :variable-default nil + :variable-document + "*Groups in which to automatically process spam or ham articles with a backend on summary exit. If non-nil, this should be a list of group name regexps that should match all groups in which to do automatic spam processing, associated with the appropriate processor. This only makes sense for mail groups." - :variable-group spam - :variable-type '(repeat :tag "Spam/Ham Processors" - (list :tag "Spam Summary Exit Processor Choices" - (regexp :tag "Group Regexp") - (set :tag "Spam/Ham Summary Exit Processor" - (variable-item gnus-group-spam-exit-processor-ifile) - (variable-item gnus-group-spam-exit-processor-stat) - (variable-item gnus-group-spam-exit-processor-bogofilter) - (variable-item gnus-group-spam-exit-processor-blacklist) - (variable-item gnus-group-ham-exit-processor-ifile) - (variable-item gnus-group-ham-exit-processor-stat) - (variable-item gnus-group-ham-exit-processor-whitelist) - (variable-item gnus-group-ham-exit-processor-BBDB)))) - :parameter-document - "Which spam processors will be applied to the spam or ham GROUP articles at summary exit.") - -(gnus-define-group-parameter - spam-process-destination - :parameter-type '(choice :tag "Destination for spam-processed articles at summary exit" - (string :tag "Move to a group") - (other :tag "Expire" nil)) - :function-document - "Where spam-processed articles will go at summary exit." - :variable gnus-spam-process-destinations - :variable-default nil - :variable-document - "*Groups in which to explicitly send spam-processed articles to + :variable-group spam + :variable-type '(repeat :tag "Spam/Ham Processors" + (list :tag "Spam Summary Exit Processor Choices" + (regexp :tag "Group Regexp") + (set :tag "Spam/Ham Summary Exit Processor" + (variable-item gnus-group-spam-exit-processor-ifile) + (variable-item gnus-group-spam-exit-processor-stat) + (variable-item gnus-group-spam-exit-processor-bogofilter) + (variable-item gnus-group-spam-exit-processor-blacklist) + (variable-item gnus-group-ham-exit-processor-ifile) + (variable-item gnus-group-ham-exit-processor-stat) + (variable-item gnus-group-ham-exit-processor-whitelist) + (variable-item gnus-group-ham-exit-processor-BBDB)))) + :parameter-document + "Which spam processors will be applied to the spam or ham GROUP articles at summary exit.") + + (gnus-define-group-parameter + spam-process-destination + :parameter-type '(choice :tag "Destination for spam-processed articles at summary exit" + (string :tag "Move to a group") + (other :tag "Expire" nil)) + :function-document + "Where spam-processed articles will go at summary exit." + :variable gnus-spam-process-destinations + :variable-default nil + :variable-document + "*Groups in which to explicitly send spam-processed articles to another group, or expire them (the default). If non-nil, this should be a list of group name regexps that should match all groups in which to do spam-processed article moving, associated with the destination group or `nil' for explicit expiration. This only makes sense for mail groups." - :variable-group spam - :variable-type '(repeat - :tag "Spam-processed articles destination" - (list - (regexp :tag "Group Regexp") - (choice - :tag "Destination for spam-processed articles at summary exit" - (string :tag "Move to a group") - (other :tag "Expire" nil)))) - :parameter-document - "Where spam-processed articles will go at summary exit.") - -(gnus-define-group-parameter - ham-process-destination - :parameter-type '(choice - :tag "Destination for ham articles at summary exit from a spam group" - (string :tag "Move to a group") - (other :tag "Do nothing" nil)) - :function-document - "Where ham articles will go at summary exit from a spam group." - :variable gnus-ham-process-destinations - :variable-default nil - :variable-document - "*Groups in which to explicitly send ham articles to + :variable-group spam + :variable-type '(repeat + :tag "Spam-processed articles destination" + (list + (regexp :tag "Group Regexp") + (choice + :tag "Destination for spam-processed articles at summary exit" + (string :tag "Move to a group") + (other :tag "Expire" nil)))) + :parameter-document + "Where spam-processed articles will go at summary exit.") + + (gnus-define-group-parameter + ham-process-destination + :parameter-type '(choice + :tag "Destination for ham articles at summary exit from a spam group" + (string :tag "Move to a group") + (other :tag "Do nothing" nil)) + :function-document + "Where ham articles will go at summary exit from a spam group." + :variable gnus-ham-process-destinations + :variable-default nil + :variable-document + "*Groups in which to explicitly send ham articles to another group, or do nothing (the default). If non-nil, this should be a list of group name regexps that should match all groups in which to do ham article moving, associated with the destination group or `nil' for explicit ignoring. This only makes sense for mail groups, and only works in spam groups." - :variable-group spam - :variable-type '(repeat - :tag "Ham articles destination" - (list - (regexp :tag "Group Regexp") - (choice - :tag "Destination for ham articles at summary exit from spam group" - (string :tag "Move to a group") - (other :tag "Expire" nil)))) - :parameter-document - "Where ham articles will go at summary exit from a spam group.") + :variable-group spam + :variable-type '(repeat + :tag "Ham articles destination" + (list + (regexp :tag "Group Regexp") + (choice + :tag "Destination for ham articles at summary exit from spam group" + (string :tag "Move to a group") + (other :tag "Expire" nil)))) + :parameter-document + "Where ham articles will go at summary exit from a spam group.")) (defcustom gnus-group-uncollapsed-levels 1 "Number of group name elements to leave alone when making a short group name." diff --git a/lisp/message.el b/lisp/message.el index 079faca..9077de5 100644 --- a/lisp/message.el +++ b/lisp/message.el @@ -3566,6 +3566,7 @@ It should typically alter the sending method in some way or other." (when (and (or (not (memq (car elem) message-sent-message-via)) + (not (message-fetch-field "supersedes")) (if (or (message-gnksa-enable-p 'multiple-copies) (not (eq (car elem) 'news))) (y-or-n-p diff --git a/lisp/nnimap.el b/lisp/nnimap.el index a459161..72289b3 100644 --- a/lisp/nnimap.el +++ b/lisp/nnimap.el @@ -197,6 +197,14 @@ RFC2060 section 6.4.4." :group 'nnimap :type 'sexp) +(defcustom nnimap-split-download-body nil + "Whether to download entire articles during splitting. +This is generally not required, and will slow things down considerably. +You may need it if you want to use an advanced splitting function that +analyses the body before splitting the article." + :group 'nnimap + :type 'boolean) + ;; Performance / bug workaround variables (defcustom nnimap-close-asynchronous t @@ -1247,7 +1255,10 @@ function is generally only called when Gnus is shutting down." (when (setq rule (nnimap-split-find-rule server inbox)) ;; iterate over articles (dolist (article (imap-search nnimap-split-predicate)) - (when (nnimap-request-head article) + (when (if nnimap-split-download-body + (and (nnimap-request-article article) + (mail-narrow-to-head)) + (nnimap-request-head article)) ;; copy article to right group(s) (setq removeorig nil) (dolist (to-group (nnimap-split-to-groups rule)) @@ -1271,6 +1282,8 @@ function is generally only called when Gnus is shutting down." (t (message "IMAP split failed to move %s:%s:%d to %s" server inbox article to-group)))) + (if nnimap-split-download-body + (widen)) ;; remove article if it was successfully copied somewhere (and removeorig (imap-message-flags-add (format "%d" article) diff --git a/texi/ChangeLog b/texi/ChangeLog index d6cec46..180211c 100644 --- a/texi/ChangeLog +++ b/texi/ChangeLog @@ -1,6 +1,7 @@ 2003-01-15 Simon Josefsson * gnus.texi (X-Face): Revert substantial part of last fix. + (Splitting in IMAP): Add. 2003-01-13 Reiner Steib diff --git a/texi/gnus-ja.texi b/texi/gnus-ja.texi index 8f32d9e..333dad0 100644 --- a/texi/gnus-ja.texi +++ b/texi/gnus-ja.texi @@ -15065,6 +15065,15 @@ nnimap $BFCM-$NFC5iJ,3dJ}<0$r(B @code{nnimap-split-fancy} $B$KDj5A$7$F2<$5$$! @end lisp Nnmail $B$GBP1~$9$k$b$N(B: @code{nnmail-split-fancy}. + +@item nnimap-split-download-body +@findex nnimap-split-download-body +@vindex nnimap-split-download-body + +$BJ,3d$7$F$$$k$H$-$K$9$Y$F$N5-;v$r%@%&%s%m!<%I$9$k$K$OHs(B-nil $B$K@_Dj$7$F2<(B +$B$5$$!#$3$l$OIaDL$OI,MW$G$O$J$/!"J*;v$rAjEv$KCY$/$7$F$7$^$&$G$7$g$&!#5-;v(B +$B$rJ,3d$9$k$?$a$KK\J8$rJ,@O$9$k9bEY$J4X?t$r;H$$$?$$>l9g$K$O!"I,MW$+$b$7$l(B +$B$^$;$s!#(B @end table @node Expiring in IMAP diff --git a/texi/gnus.texi b/texi/gnus.texi index 189bfa4..5069f89 100644 --- a/texi/gnus.texi +++ b/texi/gnus.texi @@ -15516,6 +15516,15 @@ Example: Nnmail equivalent: @code{nnmail-split-fancy}. +@item nnimap-split-download-body +@findex nnimap-split-download-body +@vindex nnimap-split-download-body + +Set to non-nil to download entire articles during splitting. This is +generally not required, and will slow things down considerably. You +may need it if you want to use an advanced splitting function that +analyses the body to split the article. + @end table @node Expiring in IMAP