From: yamaoka Date: Wed, 14 Aug 2002 22:56:14 +0000 (+0000) Subject: Synch with Oort Gnus. X-Git-Tag: t-gnus-6_15_8-01-quimby~36 X-Git-Url: http://git.chise.org/gitweb/?a=commitdiff_plain;h=3f6759faeb3ae2e1526c180f43b39b97b65551d4;p=elisp%2Fgnus.git- Synch with Oort Gnus. --- diff --git a/contrib/hashcash.el b/contrib/hashcash.el index d87edad..b3c32fc 100644 --- a/contrib/hashcash.el +++ b/contrib/hashcash.el @@ -1,6 +1,5 @@ ;;; hashcash.el --- Add hashcash payments to email -;; $Revision: 1.1.2.4 $ ;; Copyright (C) 1997,2001 Paul E. Foley ;; Maintainer: Paul Foley @@ -35,9 +34,13 @@ ADDR is the email address of the intended recipient and AMOUNT is the value of hashcash payment to be made to that user. STRING, if present, is the string to be hashed; if not present ADDR will be used.") -(defcustom hashcash "hashcash" +(defcustom hashcash "/usr/local/bin/hashcash" "*The path to the hashcash binary.") +(defcustom hashcash-in-news nil + "*Specifies whether or not hashcash payments should be made to newsgroups." + :type 'boolean) + (require 'mail-utils) (defun hashcash-strip-quoted-names (addr) @@ -103,13 +106,13 @@ Prefix arg sets default payment temporarily." (narrow-to-region (point-min) (point)) (let ((to (hashcash-strip-quoted-names (mail-fetch-field "To" nil t))) (cc (hashcash-strip-quoted-names (mail-fetch-field "Cc" nil t))) - (ng (hashcash-strip-quoted-names - (mail-fetch-field "Newsgroups" nil t)))) + (ng (hashcash-strip-quoted-names (mail-fetch-field "Newsgroups" + nil t)))) (when to (setq addrlist (split-string to ",[ \t\n]*"))) (when cc (setq addrlist (nconc addrlist (split-string cc ",[ \t\n]*")))) - (when ng + (when (and hashcash-in-news ng) (setq addrlist (nconc addrlist (split-string ng ",[ \t\n]*"))))) (while addrlist (hashcash-insert-payment (pop addrlist)))))) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 4b1c73f..588487e 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,15 @@ +2002-08-14 Simon Josefsson + + * gnus-art.el (gnus-button-alist): Use ' not ` for default value + quoting. + (gnus-button-alist): Fix doc. + (gnus-header-button-alist): Use ' not ` for default value quoting. + (gnus-header-button-alist): Don't inline gnus-button-url-regexp, + rationale similar to 2002-05-01 change. + (gnus-article-add-buttons-to-head): Evaluate expression. + + * gnus-sum.el (gnus-summary-make-menu-bar): Add MIME button option. + 2002-08-14 Katsumi Yamaoka * message.el (message-font-lock-keywords): Refer to the value for diff --git a/lisp/gnus-art.el b/lisp/gnus-art.el index 163c87b..9fff9e2 100644 --- a/lisp/gnus-art.el +++ b/lisp/gnus-art.el @@ -5722,7 +5722,7 @@ after replacing with the original article." :type 'regexp) (defcustom gnus-button-alist - `(("<\\(url:[>\n\t ]*?\\)?\\(nntp\\|news\\):[>\n\t ]*\\([^>\n\t ]*@[^>\n\t ]*\\)>" + '(("<\\(url:[>\n\t ]*?\\)?\\(nntp\\|news\\):[>\n\t ]*\\([^>\n\t ]*@[^>\n\t ]*\\)>" 0 t gnus-button-handle-news 3) ("\\b\\(nntp\\|news\\):\\([^>\n\t ]*@[^>)!;:,\n\t ]*\\)" 0 t gnus-button-handle-news 2) @@ -5745,7 +5745,8 @@ after replacing with the original article." "*Alist of regexps matching buttons in article bodies. Each entry has the form (REGEXP BUTTON FORM CALLBACK PAR...), where -REGEXP: is the string matching text around the button, +REGEXP: is the string matching text around the button (can also be lisp +expression evaluating to a string), BUTTON: is the number of the regexp grouping actually matching the button, FORM: is a lisp expression which must eval to true for the button to be added, @@ -5764,14 +5765,14 @@ variable it the real callback function." (integer :tag "Regexp group"))))) (defcustom gnus-header-button-alist - `(("^\\(References\\|Message-I[Dd]\\):" "<[^<>]+>" + '(("^\\(References\\|Message-I[Dd]\\):" "<[^<>]+>" 0 t gnus-button-message-id 0) ("^\\(From\\|Reply-To\\):" ": *\\(.+\\)$" 1 t gnus-button-reply 1) ("^\\(Cc\\|To\\):" "[^ \t\n<>,()\"]+@[^ \t\n<>,()\"]+" 0 t gnus-button-mailto 0) - ("^X-[Uu][Rr][Ll]:" ,gnus-button-url-regexp 0 t browse-url 0) - ("^Subject:" ,gnus-button-url-regexp 0 t browse-url 0) - ("^[^:]+:" ,gnus-button-url-regexp 0 t browse-url 0) + ("^X-[Uu][Rr][Ll]:" gnus-button-url-regexp 0 t browse-url 0) + ("^Subject:" gnus-button-url-regexp 0 t browse-url 0) + ("^[^:]+:" gnus-button-url-regexp 0 t browse-url 0) ("^[^:]+:" "\\bmailto:\\([-a-zA-Z.@_+0-9%=?]+\\)" 0 t gnus-url-mailto 1) ("^[^:]+:" "\\(<\\(url: \\)?news:\\([^>\n ]*\\)>\\)" 1 t gnus-button-message-id 3)) @@ -6025,7 +6026,7 @@ specified by `gnus-button-alist'." (match-beginning 0)) (point-max))) (goto-char beg) - (while (re-search-forward (nth 1 entry) end t) + (while (re-search-forward (eval (nth 1 entry)) end t) ;; Each match within a header. (let* ((entry (cdr entry)) (start (match-beginning (nth 1 entry)))