+2003-10-27 Simon Josefsson <jas@extundo.com>
+
+ * pgg-gpg.el (pgg-gpg-possibly-cache-passphrase): New optional
+ parameter key, overrides the key id used to store passphrase
+ under (uses true key id from gpg output if nil).
+ (pgg-gpg-encrypt-region): Search for passphrase using user suplied
+ string STR, instead of (pgg-lookup-key STR t).
+ (pgg-gpg-encrypt-region): Store passphrase under user suplied
+ string, instead of real key id taken from gpg output.
+ (pgg-gpg-decrypt-region): Likewise.
+ (pgg-gpg-sign-region): Likewise.
+ * pgg.el (pgg-decrypt-region): Don't set pgg-default-user-id.
+
+2003-10-27 Romain FRANCOISE <romain@orebokech.com>
+
+ * gnus-art.el (gnus-article-goto-prev-page): Doc fix.
+
+2003-10-27 Simon Josefsson <jas@extundo.com>
+
+ * mm-bodies.el (mm-body-encoding): Don't use QP when message body
+ only consists of short lines and ASCII, when
+ mm-use-ultra-safe-encoding. Refer to 'About foo' thread in
+ gnus-bug, e.g. <ilullrg4k7p.fsf@extundo.com>, for more discussion.
+ This make it possible to pipe the raw RFC 822 message into 'gpg'
+ and have the signature work. Potential problem: what if message
+ contain data that would be dash-escaped by OpenPGP
+ implementations? Then PGP 2.x might not be able to parse the raw
+ RFC 822 message correctly. If that problem is worth fixing, it
+ should be fixed by detecting the situation, instead of applying QP
+ to everything. Based on discussion with "John A. Martin"
+ <jam@jamux.com>.
+
+2003-10-27 Teodor Zlatanov <tzz@lifelogs.com>
+
+ * spam.el (spam-mark-spam-as-expired-and-move-routine)
+ (spam-ham-copy-or-move-routine): don't ask when deleting copied
+ articles, and use move instead of copy when possible
+ (spam-split): added the option of specifying a string as a
+ spam-split parameter; such a string will override
+ spam-split-group temporarily.
+
+ * nnmail.el (nnmail-cache-insert): protect from nil message IDs,
+ but should we do something else?
+
+ * gnus-registry.el (gnus-registry-spool-action): protect from nil
+ message IDs
+
2003-10-26 Simon Josefsson <jas@extundo.com>
* gnus-art.el (gnus-button-alist): Allow & in mailto URLs.
(defun gnus-article-goto-prev-page ()
- "Show the next page of the article."
+ "Show the previous page of the article."
(interactive)
(if (bobp)
(gnus-article-read-summary-keys nil (gnus-character-to-event ?p))
;; do not process the draft IDs
; (unless (string-match "totally-fudged-out-message-id" id)
; (let ((group (gnus-group-guess-full-name group)))
- (when (string-match "\r$" id)
+ (when (and (stringp id) (string-match "\r$" id))
(setq id (substring id 0 -1)))
(gnus-message 5 "Registry: article %s spooled to %s"
id
(longp (mm-long-lines-p 1000)))
(require 'message)
(cond
- ((and (not mm-use-ultra-safe-encoding)
- (not longp)
+ ((and (not longp)
(eq bits '7bit))
bits)
((and (not mm-use-ultra-safe-encoding)
(defvar group-art-list)
(defvar group-art)
(defun nnmail-cache-insert (id grp &optional subject)
- (run-hook-with-args 'nnmail-spool-hook
- id grp subject)
- (when nnmail-treat-duplicates
- ;; Store some information about the group this message is written
- ;; to. This is passed in as the grp argument -- all locations this
- ;; has been called from have been checked and the group is available.
- ;; The only ambiguous case is nnmail-check-duplication which will only
- ;; pass the first (of possibly >1) group which matches. -Josh
- (unless (gnus-buffer-live-p nnmail-cache-buffer)
- (nnmail-cache-open))
- (save-excursion
- (set-buffer nnmail-cache-buffer)
- (goto-char (point-max))
- (if (and grp (not (string= "" grp))
- (gnus-methods-equal-p gnus-command-method
- (nnmail-cache-primary-mail-backend)))
- (let ((regexp (if (consp nnmail-cache-ignore-groups)
- (mapconcat 'identity nnmail-cache-ignore-groups
- "\\|")
- nnmail-cache-ignore-groups)))
- (unless (and regexp (string-match regexp grp))
- (insert id "\t" grp "\n")))
- (insert id "\n")))))
-
+ (when (stringp id)
+ (run-hook-with-args 'nnmail-spool-hook
+ id grp subject)
+ (when nnmail-treat-duplicates
+ ;; Store some information about the group this message is written
+ ;; to. This is passed in as the grp argument -- all locations this
+ ;; has been called from have been checked and the group is available.
+ ;; The only ambiguous case is nnmail-check-duplication which will only
+ ;; pass the first (of possibly >1) group which matches. -Josh
+ (unless (gnus-buffer-live-p nnmail-cache-buffer)
+ (nnmail-cache-open))
+ (save-excursion
+ (set-buffer nnmail-cache-buffer)
+ (goto-char (point-max))
+ (if (and grp (not (string= "" grp))
+ (gnus-methods-equal-p gnus-command-method
+ (nnmail-cache-primary-mail-backend)))
+ (let ((regexp (if (consp nnmail-cache-ignore-groups)
+ (mapconcat 'identity nnmail-cache-ignore-groups
+ "\\|")
+ nnmail-cache-ignore-groups)))
+ (unless (and regexp (string-match regexp grp))
+ (insert id "\t" grp "\n")))
+ (insert id "\n"))))))
+
(defun nnmail-cache-primary-mail-backend ()
(let ((be-list (cons gnus-select-method gnus-secondary-select-methods))
(be nil)
(defun spam-mark-spam-as-expired-and-move-routine (&rest groups)
(gnus-summary-kill-process-mark)
(let ((articles gnus-newsgroup-articles)
- article tomove todelete)
+ article tomove deletep)
(dolist (article articles)
(when (eq (gnus-summary-article-mark article) gnus-spam-mark)
(gnus-summary-mark-article article gnus-expirable-mark)
(dolist (article tomove)
(gnus-summary-set-process-mark article))
(when tomove
- (gnus-summary-copy-article nil group)
- (setq todelete t))))
+ (if (> (length groups) 1)
+ (progn
+ (gnus-summary-copy-article nil group)
+ (setq deletep t))
+ (gnus-summary-move-article nil group)))))
;; now delete the articles, if there was a copy done
- (when todelete
+ (when deletep
(dolist (article tomove)
(gnus-summary-set-process-mark article))
(when tomove
- (gnus-summary-delete-article nil)))
+ (let ((gnus-novice-user nil)) ; don't ask me if I'm sure
+ (gnus-summary-delete-article nil))))
(gnus-summary-yank-process-mark)))
(defun spam-ham-copy-or-move-routine (copy groups)
(gnus-summary-kill-process-mark)
(let ((articles gnus-newsgroup-articles)
- article mark todo todelete)
+ article mark todo deletep)
(dolist (article articles)
(when (spam-group-ham-mark-p gnus-newsgroup-name
(gnus-summary-article-mark article))
(when spam-mark-ham-unread-before-move-from-spam-group
(gnus-summary-mark-article article gnus-unread-mark))
(gnus-summary-set-process-mark article))
- (gnus-summary-copy-article nil group)
- (setq todelete t)))
+
+ (if (> (length groups) 1)
+ (progn
+ (gnus-summary-copy-article nil group)
+ (setq deletep t))
+ (gnus-summary-move-article nil group))))
- ;; now delete the articles, unless copy is t, and when there was a copy done
+ ;; now delete the articles, unless a) copy is t, and when there was a copy done
+ ;; b) a move was done to a single group
(unless copy
- (when todelete
+ (when deletep
(dolist (article todo)
(gnus-summary-set-process-mark article))
(when todo
- (gnus-summary-delete-article nil)))))
+ (let ((gnus-novice-user nil)) ; don't ask me if I'm sure
+ (gnus-summary-delete-article nil))))))
(gnus-summary-yank-process-mark))
;;;TODO: modify to invoke self with each specific check if invoked without specific checks
(defun spam-split (&rest specific-checks)
"Split this message into the `spam' group if it is spam.
-This function can be used as an entry in `nnmail-split-fancy', for
-example like this: (: spam-split). It can take checks as parameters.
+This function can be used as an entry in `nnmail-split-fancy',
+for example like this: (: spam-split). It can take checks as
+parameters. A string as a parameter will set the
+spam-split-group to that string.
See the Info node `(gnus)Fancy Mail Splitting' for more details."
(interactive)
- (save-excursion
- (save-restriction
- (dolist (check spam-list-of-statistical-checks)
- (when (symbol-value check)
- (widen)
- (gnus-message 8 "spam-split: widening the buffer (%s requires it)"
- (symbol-name check))
- (return)))
- ;; (progn (widen) (debug (buffer-string)))
- (let ((list-of-checks spam-list-of-checks)
- decision)
- (while (and list-of-checks (not decision))
- (let ((pair (pop list-of-checks)))
- (when (and (symbol-value (car pair))
- (or (null specific-checks)
- (memq (car pair) specific-checks)))
- (gnus-message 5 "spam-split: calling the %s function" (symbol-name (cdr pair)))
- (setq decision (funcall (cdr pair))))))
- (if (eq decision t)
- nil
- decision)))))
+ (let ((spam-split-group-choice spam-split-group))
+ (dolist (check specific-checks)
+ (when (stringp check)
+ (setq spam-split-group-choice check)
+ (setq specific-checks (delq check specific-checks))))
+
+ (let ((spam-split-group spam-split-group-choice))
+ (save-excursion
+ (save-restriction
+ (dolist (check spam-list-of-statistical-checks)
+ (when (and (symbolp check) (symbol-value check))
+ (widen)
+ (gnus-message 8 "spam-split: widening the buffer (%s requires it)"
+ (symbol-name check))
+ (return)))
+ ;; (progn (widen) (debug (buffer-string)))
+ (let ((list-of-checks spam-list-of-checks)
+ decision)
+ (while (and list-of-checks (not decision))
+ (let ((pair (pop list-of-checks)))
+ (when (and (symbol-value (car pair))
+ (or (null specific-checks)
+ (memq (car pair) specific-checks)))
+ (gnus-message 5 "spam-split: calling the %s function"
+ (symbol-name (cdr pair)))
+ (setq decision (funcall (cdr pair))))))
+ (if (eq decision t)
+ nil
+ decision)))))))
(defun spam-setup-widening ()
(dolist (check spam-list-of-statistical-checks)
+2003-10-27 Teodor Zlatanov <tzz@lifelogs.com>
+
+ * gnus.texi (Filtering Spam Using The Spam ELisp Package): added
+ example of using a string as a parameter to spam-split in order
+ to override the default spam-split-group value
+
+2003-10-27 Jesper Harder <harder@ifa.au.dk>
+
+ * gnusref.tex (subsection*{Notes}): do.
+
+ * gnus.texi (Exiting the Summary Buffer): Add keybinding.
+
2003-10-23 Reiner Steib <Reiner.Steib@gmx.de>
* emacs-mime.texi: Markup: Use @acronym for MML and MIME.
@table @kbd
@item Z Z
+@itemx Z Q
@itemx q
@kindex Z Z (\e$B35N,\e(B)
+@kindex Z Q (\e$B35N,\e(B)
@findex q (\e$B35N,\e(B)
@findex gnus-summary-exit
@vindex gnus-summary-exit-hook
\e$B$9\e(B (@code{gnus-summary-catchup-and-goto-next-group})\e$B!#\e(B
@item Z R
+@itemx C-x C-s
@kindex Z R (\e$B35N,\e(B)
+@kindex C-x C-s (\e$B35N,\e(B)
@findex gnus-summary-reselect-current-group
\e$B8=:_$N%0%k!<%W$r=P$F!"$=$l$+$iF~$jD>$7$^\e(B
\e$B$9\e(B (@code{gnus-summary-reselect-current-group})\e$B!#$b$7@\F,0z?t$rM?$($i$l\e(B
@code{spam-split-group} \e$B$r%+%9%?%^%$%:$9$k$3$H$,2DG=$G$9!#\e(B
\e$B$^$?!"\e(B@code{spam-split} \e$B$K%Q%i%a!<%?!"Nc$(\e(B
-\e$B$P\e(B @samp{spam-use-regex-headers} \e$B$rM?$($k$3$H$b$G$-$^$9!#$J$<$3$l$,M-MQ\e(B
-\e$B$J$N$G$7$g$&$+\e(B?
+\e$B$P\e(B @samp{spam-use-regex-headers} \e$B$^$?$O\e(B @samp{"maybe-spam"} \e$B$rM?$($k$3$H\e(B
+\e$B$b$G$-$^$9!#$J$<$3$l$,M-MQ$J$N$G$7$g$&$+\e(B?
\e$B$3$l$i$N\e(B (@code{spam-use-regex-headers} \e$B$H\e(B @code{spam-use-blackholes} \e$B$N\e(B
\e$B@_Dj$K$h$k\e(B) \e$BJ,3d$N5,B'$r8+$F2<$5$$\e(B:
@example
nnimap-split-fancy '(|
- (: spam-split 'spam-use-regex-headers)
+;;; spam-use-regex-headers \e$B$G8!=P$5$l$?$9$Y$F$N\e(B spam \e$B$O\e(B "regex-spam" \e$B$X!#\e(B
+ (: spam-split "regex-spam" 'spam-use-regex-headers)
(any "ding" "ding")
+;;; spam-split \e$B$G8!=P$5$l$?B>$N$9$Y$F$N\e(B spam \e$B$O\e(B spam-split-group \e$B$X!#\e(B
(: spam-split)
;; default mailbox
"mail")
@end example
\e$B4pK\E*$K!"$3$l$OFC$K$"$J$?$NI,MW$K0MB8$7$?FCDj$N\e(B @code{spam-split} \e$B8!\e(B
-\e$B::$r5/F0$5$;$^$9!#$9$Y$F$N%a!<%k$r$9$Y$F$N\e(B spam \e$B%F%9%H$KEj$2$kI,MW$O$"$j\e(B
-\e$B$^$;$s!#$3$l$,NI$$JL$NM}M3$O!"5,B'$r;}$C$F$$$k%a!<%j%s%0%j%9%H$X$N%a%C%;!<\e(B
-\e$B%8$KBP$7$F!";q8;=8LsE*$J%V%i%C%/%[!<%k!&%A%'%C%/$r<B9T$9$kI,MW$,$J$$$H$$\e(B
-\e$B$&$3$H$G$9!#$5$i$K\e(B nnmail \e$BJ,3d$KBP$7$F\e(B nnimap \e$BJ,3d$N$?$a$N!"0[$J\e(B
-\e$B$k\e(B spam \e$B8!::$r;XDj$9$k$3$H$b$G$-$^$9!#5$$,68$&!<!#\e(B
+\e$B::$r5/F0$5$;!"$=$l$i$N8!::$N7k2L$OFCDj$N\e(B spam \e$B%0%k!<%W$r;X$7<($7$^$9!#$9\e(B
+\e$B$Y$F$N%a!<%k$r$9$Y$F$N\e(B spam \e$B%F%9%H$KEj$2$kI,MW$O$"$j$^$;$s!#$3$l$,NI$$JL\e(B
+\e$B$NM}M3$O!"5,B'$r;}$C$F$$$k%a!<%j%s%0%j%9%H$X$N%a%C%;!<%8$KBP$7$F!";q8;=8\e(B
+\e$BLsE*$J%V%i%C%/%[!<%k!&%A%'%C%/$r<B9T$9$kI,MW$,$J$$$H$$$&$3$H$G$9!#$5$i\e(B
+\e$B$K\e(B nnmail \e$BJ,3d$KBP$7$F\e(B nnimap \e$BJ,3d$N$?$a$N!"0[$J$k\e(B spam \e$B8!::$r;XDj$9$k$3\e(B
+\e$B$H$b$G$-$^$9!#5$$,68$&!<!#\e(B
\e$B8!::$HF1;~$KL@$i$+$K\e(B @code{spam-split} \e$B$r<B9T$9$k$H$7$F$b!":#$^$G$H$*\e(B
\e$B$j\e(B @code{spam-use-regex-headers} \e$B$r\e(B @code{t} \e$B$K@_Dj$9$k$h$&$J8!::$r9T$C\e(B
@table @kbd
@item Z Z
+@itemx Z Q
@itemx q
@kindex Z Z (Summary)
+@kindex Z Q (Summary)
@kindex q (Summary)
@findex gnus-summary-exit
@vindex gnus-summary-exit-hook
(@code{gnus-summary-catchup-and-goto-next-group}).
@item Z R
+@itemx C-x C-s
@kindex Z R (Summary)
+@kindex C-x C-s (Summary)
@findex gnus-summary-reselect-current-group
Exit this group, and then enter it again
(@code{gnus-summary-reselect-current-group}). If given a prefix, select
but you can customize @code{spam-split-group}.
You can also give @code{spam-split} a parameter,
-e.g. @samp{'spam-use-regex-headers}. Why is this useful?
+e.g. @samp{'spam-use-regex-headers} or @samp{"maybe-spam"}. Why is
+this useful?
Take these split rules (with @code{spam-use-regex-headers} and
@code{spam-use-blackholes} set):
@example
nnimap-split-fancy '(|
- (: spam-split 'spam-use-regex-headers)
+;;; all spam detected by spam-use-regex-headers goes to "regex-spam"
+ (: spam-split "regex-spam" 'spam-use-regex-headers)
(any "ding" "ding")
+;;; all other spam detected by spam-split goes to spam-split-group
(: spam-split)
;; default mailbox
"mail")
@end example
Basically, this lets you invoke specific @code{spam-split} checks
-depending on your particular needs. You don't have to throw all mail
+depending on your particular needs, and to target the results of those
+checks to a particular spam group. 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
%% include file for the Gnus refcard and booklet
\def\progver{5.10}\def\refver{5.10-1} % program and refcard versions
-\def\date{May, 2003}
+\def\date{Oct, 2003}
\def\author{Gnus Bugfixing Girls + Boys $<$bugs@gnus.org$>$}
%%
Z P & Exit and go to the {\bf previous} group.\\
%
Z G & (M-g) Check for new articles in this group ({\bf get}).\\
- Z R & Exit this group, and then enter it again ({\bf reenter}).
+ Z R & (C-x C-s) Exit this group, and then enter it again ({\bf reenter}).
[Prefix: select all articles, read and unread.]\\
Z s & Update and save the dribble buffer. [Prefix: save .newsrc* as well]\\
\end{keys}