From: yamaoka Date: Wed, 14 Feb 2001 03:26:53 +0000 (+0000) Subject: Synch with Oort Gnus. X-Git-Tag: t-gnus-6_15_0-07-quimby~1 X-Git-Url: http://git.chise.org/gitweb/?a=commitdiff_plain;h=722563085c7278c396f713ec3f549c12c5419d61;p=elisp%2Fgnus.git- Synch with Oort Gnus. * lisp/gnus-vers.el (gnus-revision-number): Increment to 07. * lisp/dgnushack.el (dgnushack-make-autoloads): Remove function. (dgnushack-make-load): Ignore cus-load.el if it does not exist. (dgnushack-make-auto-load): Remove auto-autoloads.el. (dgnushack-make-cus-load): Do nothing if loading cus-dep is failed. * lisp/Makefile.in (clean): Remove gnus-load.el instead of custom-load.el. (compose-package): Call `gnus-load.elc' and then rename gnus-load.el(c) to auto-autoloads.el(c) instead of the use of `dgnushack-make-autoloads'. (clever): No need to remove custom-load.el. * Makefile.in (elclean): Remove gnus-load.el instead of custom-load.el. * aclocal.m4 (AC_CHECK_URL): Ignore cache. --- diff --git a/ChangeLog b/ChangeLog index 7e6418f..cf57fcc 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,28 @@ +2001-02-14 Katsumi Yamaoka + + * lisp/gnus-vers.el (gnus-revision-number): Increment to 07. + + * lisp/dgnushack.el (dgnushack-make-autoloads): Remove function. + (dgnushack-make-load): Ignore cus-load.el if it does not exist. + (dgnushack-make-auto-load): Remove auto-autoloads.el. + (dgnushack-make-cus-load): Do nothing if loading cus-dep is failed. + + * lisp/Makefile.in (clean): Remove gnus-load.el instead of + custom-load.el. + (compose-package): Call `gnus-load.elc' and then rename + gnus-load.el(c) to auto-autoloads.el(c) instead of the use of + `dgnushack-make-autoloads'. + (clever): No need to remove custom-load.el. + + * Makefile.in (elclean): Remove gnus-load.el instead of + custom-load.el. + + * aclocal.m4 (AC_CHECK_URL): Ignore cache. + +2001-02-13 Katsumi Yamaoka + + * lisp/gnus-vers.el (gnus-revision-number): Increment to 06. + 2001-02-11 18:00:00 ShengHuo ZHU * GNUS-NEWS: Copyright and others. diff --git a/Makefile.in b/Makefile.in index 33bb635..7fdbdfd 100644 --- a/Makefile.in +++ b/Makefile.in @@ -163,7 +163,7 @@ clean: for i in lisp texi; do (cd $$i; $(MAKE) clean); done elclean: - cd lisp && rm -f *.elc auto-autoloads.el custom-load.el + cd lisp && rm -f *.elc auto-autoloads.el gnus-load.el x: $(MAKE) EMACS="$(XEMACS)" diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 85a7cb7..c1021fc 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,24 @@ +2001-02-13 20:00:00 ShengHuo ZHU + + * gnus.el (to-address): Define parameter. + (to-list): Ditto. + * gnus-art.el (article-hide-boring-headers): Use them. + * gnus-msg.el (gnus-post-news): Ditto. + +2001-02-13 19:00:00 ShengHuo ZHU + + * gnus-draft.el (gnus-draft-reminder): New. + + * gnus-art.el (gnus-sender-save-name): New. + +2001-02-13 18:00:00 ShengHuo ZHU + + * mm-util.el (mm-mime-charset): Error message. + +2001-02-13 11:00:00 ShengHuo ZHU + + * message.el (message-check-news-body-syntax): Don't check mml lines. + 2001-02-12 11:00:00 ShengHuo ZHU * gnus-topic.el (gnus-subscribe-topics): Return nil if not diff --git a/lisp/Makefile.in b/lisp/Makefile.in index e31b705..c631548 100644 --- a/lisp/Makefile.in +++ b/lisp/Makefile.in @@ -43,8 +43,8 @@ clever some: gnus-load.elc fi; \ if test $$RM_ELC = t; then \ echo " => maybe yes;" \ - "rm -f *.elc auto-autoloads.el custom-load.el"; \ - rm -f *.elc auto-autoloads.el custom-load.el; \ + "rm -f *.elc auto-autoloads.el"; \ + rm -f *.elc auto-autoloads.el; \ else \ echo " => maybe unnecessary"; \ fi; \ @@ -69,8 +69,9 @@ install-package-manifest: $(EMACS_COMP) -f dgnushack-install-package-manifest \ $(PACKAGEDIR) $(GNUS_PRODUCT_NAME) -compose-package: - $(EMACS_COMP) -f dgnushack-make-autoloads +compose-package: gnus-load.elc + mv gnus-load.el auto-autoloads.el; \ + mv gnus-load.elc auto-autoloads.elc remove-extra-files-in-package: $(EMACS_COMP) -f dgnushack-remove-extra-files-in-package \ @@ -100,8 +101,7 @@ gnus-load.elc: $(EMACS_COMP) -f dgnushack-make-load clean: - rm -f *.orig *.rej *.elc *~ - rm -f auto-autoloads.el custom-load.el + rm -f *.orig *.rej *.elc *~ auto-autoloads.el gnus-load.el distclean: clean rm -f Makefile dgnuspath.el diff --git a/lisp/dgnushack.el b/lisp/dgnushack.el index a5dccb9..b582dbf 100644 --- a/lisp/dgnushack.el +++ b/lisp/dgnushack.el @@ -361,8 +361,9 @@ Modify to suit your needs.")) (require 'gnus) (byte-recompile-directory "." 0)) -(defvar dgnushack-gnus-load-file (expand-file-name "gnus-load.el")) -(defvar dgnushack-cus-load-file (expand-file-name "cus-load.el")) +(defvar dgnushack-gnus-load-file (expand-file-name "gnus-load.el" srcdir)) +(defvar dgnushack-cus-load-file (expand-file-name "cus-load.el" srcdir)) +(defvar dgnushack-auto-load-file (expand-file-name "auto-autoloads.el" srcdir)) (defun dgnushack-make-cus-load () (when (condition-case nil @@ -379,8 +380,11 @@ Modify to suit your needs.")) (make-backup-files nil) (autoload-package-name "gnus")) (if (featurep 'xemacs) - (if (file-exists-p generated-autoload-file) - (delete-file generated-autoload-file)) + (progn + (if (file-exists-p generated-autoload-file) + (delete-file generated-autoload-file)) + (if (file-exists-p dgnushack-auto-load-file) + (delete-file dgnushack-auto-load-file))) (with-temp-file generated-autoload-file (insert ?\014))) (if (featurep 'xemacs) @@ -401,26 +405,33 @@ Modify to suit your needs.")) (defun dgnushack-make-load () (message (format "Generating %s..." dgnushack-gnus-load-file)) (with-temp-file dgnushack-gnus-load-file - (insert-file-contents dgnushack-cus-load-file) - (delete-file dgnushack-cus-load-file) - (goto-char (point-min)) - (search-forward ";;; Code:") - (forward-line) - (delete-region (point-min) (point)) - (insert "\ + (if (file-exists-p dgnushack-cus-load-file) + (progn + (insert-file-contents dgnushack-cus-load-file) + (delete-file dgnushack-cus-load-file) + (goto-char (point-min)) + (search-forward ";;; Code:") + (forward-line) + (delete-region (point-min) (point)) + (insert "\ ;;; gnus-load.el --- automatically extracted custom dependencies and autoload ;; ;;; Code: ") - (goto-char (point-max)) - (if (search-backward "custom-versions-load-alist" nil t) - (forward-line -1) - (forward-line -1) - (while (eq (char-after) ?\;) - (forward-line -1)) - (forward-line)) - (delete-region (point) (point-max)) - (insert "\n") + (goto-char (point-max)) + (if (search-backward "custom-versions-load-alist" nil t) + (forward-line -1) + (forward-line -1) + (while (eq (char-after) ?\;) + (forward-line -1)) + (forward-line)) + (delete-region (point) (point-max)) + (insert "\n")) + (insert "\ +;;; gnus-load.el --- automatically extracted autoload +;; +;;; Code: +")) ;; smiley-* are duplicated. Remove them all. (let ((point (point))) (insert-file-contents dgnushack-gnus-load-file) @@ -467,42 +478,6 @@ Modify to suit your needs.")) regexp) "Regexp matching Japanese info files.") -(defun dgnushack-make-autoloads () - "Make auto-autoloads.el, custom-load.el and then compile them." - (let ((auto-autoloads (expand-file-name "auto-autoloads.el" srcdir)) - (custom-load (expand-file-name "custom-load.el" srcdir))) - (unless (and (file-exists-p auto-autoloads) - (file-exists-p (concat auto-autoloads "c")) - (file-newer-than-file-p (concat auto-autoloads "c") - auto-autoloads) - (file-exists-p custom-load) - (file-exists-p (concat custom-load "c")) - (file-newer-than-file-p (concat custom-load "c") - custom-load)) - (let (make-backup-files) - (message "Updating autoloads for directory %s..." default-directory) - (let ((generated-autoload-file auto-autoloads) - (si:message (symbol-function 'message)) - noninteractive) - (defun message (fmt &rest args) - (cond ((and (string-equal "Generating autoloads for %s..." fmt) - (file-exists-p (file-name-nondirectory (car args)))) - (funcall si:message - fmt (file-name-nondirectory (car args)))) - ((string-equal "No autoloads found in %s" fmt)) - ((string-equal "Generating autoloads for %s...done" fmt)) - (t (apply si:message fmt args)))) - (unwind-protect - (update-autoloads-from-directory default-directory) - (fset 'message si:message))) - (byte-compile-file auto-autoloads) - (with-temp-buffer - (let ((standard-output (current-buffer))) - (Custom-make-dependencies ".")) - (message "%s" (buffer-string))) - (require 'cus-load) - (byte-compile-file custom-load))))) - (defun dgnushack-remove-extra-files-in-package () "Remove extra files in the lisp directory of the XEmacs package." (let ((lisp-dir (expand-file-name (concat "lisp/" diff --git a/lisp/gnus-art.el b/lisp/gnus-art.el index 2590b0c..48cabd1 100644 --- a/lisp/gnus-art.el +++ b/lisp/gnus-art.el @@ -1404,9 +1404,9 @@ always hide." ((eq elem 'to-address) (let ((to (message-fetch-field "to")) (to-address - (gnus-group-find-parameter + (gnus-parameter-to-address (if (boundp 'gnus-newsgroup-name) - gnus-newsgroup-name "") 'to-address))) + gnus-newsgroup-name "")))) (when (and to to-address (ignore-errors (gnus-string-equal @@ -2960,6 +2960,15 @@ If variable `gnus-use-long-file-name' is non-nil, it is (expand-file-name "news" (gnus-newsgroup-directory-form newsgroup))) gnus-article-save-directory))) +(defun gnus-sender-save-name (newsgroup headers &optional last-file) + "Generate file name from sender." + (let ((from (mail-header-from headers))) + (expand-file-name + (if (and from (string-match "\\([^ <]+\\)@" from)) + (match-string 1 from) + "nobody") + gnus-article-save-directory))) + (defun article-verify-x-pgp-sig () "Verify X-PGP-Sig." (interactive) diff --git a/lisp/gnus-cus.el b/lisp/gnus-cus.el index aff531b..d4268af 100644 --- a/lisp/gnus-cus.el +++ b/lisp/gnus-cus.el @@ -74,36 +74,7 @@ if that value is non-nil." ;;; Group Customization: (defconst gnus-group-parameters - '((to-address (gnus-email-address :tag "To Address") "\ -This will be used when doing followups and posts. - -This is primarily useful in mail groups that represent closed -mailing lists--mailing lists where it's expected that everybody that -writes to the mailing list is subscribed to it. Since using this -parameter ensures that the mail only goes to the mailing list itself, -it means that members won't receive two copies of your followups. - -Using `to-address' will actually work whether the group is foreign or -not. Let's say there's a group on the server that is called -`fa.4ad-l'. This is a real newsgroup, but the server has gotten the -articles from a mail-to-news gateway. Posting directly to this group -is therefore impossible--you have to send mail to the mailing list -address instead. - -The gnus-group-split mail splitting mechanism will behave as if this -address was listed in gnus-group-split Addresses (see below).") - - (to-list (gnus-email-address :tag "To List") "\ -This address will be used when doing a `a' in the group. - -It is totally ignored when doing a followup--except that if it is -present in a news group, you'll get mail group semantics when doing -`f'. - -The gnus-group-split mail splitting mechanism will behave as if this -address was listed in gnus-group-split Addresses (see below).") - - (extra-aliases (choice + '((extra-aliases (choice :tag "Extra Aliases" (list :tag "List" @@ -306,8 +277,8 @@ DOC is a documentation string for the parameter.") :doc ,(nth 2 entry) (const :format "" ,(nth 0 entry)) ,(nth 1 entry))) - (append gnus-group-parameters - (reverse gnus-group-parameters-more) + (append (reverse gnus-group-parameters-more) + gnus-group-parameters (if group gnus-extra-group-parameters gnus-extra-topic-parameters))))) diff --git a/lisp/gnus-draft.el b/lisp/gnus-draft.el index 7106b0f..c5c48d6 100644 --- a/lisp/gnus-draft.el +++ b/lisp/gnus-draft.el @@ -199,6 +199,20 @@ (- total (length articles)) total))) (gnus-draft-send article))))))) +;;;###autoload +(defun gnus-draft-reminder () + "Reminder user if there are unsent drafts." + (interactive) + (if (gnus-alive-p) + (let (active) + (catch 'continue + (dolist (group '("nndraft:drafts" "nndraft:queue")) + (setq active (gnus-activate-group group)) + (if (and active (>= (cdr active) (car active))) + (if (y-or-n-p "There are unsent drafts. Continue?") + (throw 'continue t) + (error "Stop!")))))))) + ;;; Utility functions (defcustom gnus-draft-decoding-function diff --git a/lisp/gnus-msg.el b/lisp/gnus-msg.el index 8e10970..927637e 100644 --- a/lisp/gnus-msg.el +++ b/lisp/gnus-msg.el @@ -595,9 +595,9 @@ header line with the old Message-ID." to-address to-group mailing-list to-list newsgroup-p) (when group - (setq to-address (gnus-group-find-parameter group 'to-address) + (setq to-address (gnus-parameter-to-address group) to-group (gnus-group-find-parameter group 'to-group) - to-list (gnus-group-find-parameter group 'to-list) + to-list (gnus-parameter-to-list group) newsgroup-p (gnus-group-find-parameter group 'newsgroup) mailing-list (when gnus-mailing-list-groups (string-match gnus-mailing-list-groups group)) diff --git a/lisp/gnus-vers.el b/lisp/gnus-vers.el index be91ca8..61bae29 100644 --- a/lisp/gnus-vers.el +++ b/lisp/gnus-vers.el @@ -31,7 +31,7 @@ (require 'product) (provide 'gnus-vers) -(defconst gnus-revision-number "06" +(defconst gnus-revision-number "07" "Revision number for this version of gnus.") ;; Product information of this gnus. diff --git a/lisp/gnus.el b/lisp/gnus.el index 23c869b..e9fb6e2 100644 --- a/lisp/gnus.el +++ b/lisp/gnus.el @@ -1475,6 +1475,49 @@ to be desirable; see the manual for further details." integer)) (gnus-define-group-parameter + to-address + :function-document + "Return GROUP's to-address." + :variable-document + "*Alist of group regexps and correspondent to-addresses." + :parameter-type '(gnus-email-address :tag "To Address") + :parameter-document "\ +This will be used when doing followups and posts. + +This is primarily useful in mail groups that represent closed +mailing lists--mailing lists where it's expected that everybody that +writes to the mailing list is subscribed to it. Since using this +parameter ensures that the mail only goes to the mailing list itself, +it means that members won't receive two copies of your followups. + +Using `to-address' will actually work whether the group is foreign or +not. Let's say there's a group on the server that is called +`fa.4ad-l'. This is a real newsgroup, but the server has gotten the +articles from a mail-to-news gateway. Posting directly to this group +is therefore impossible--you have to send mail to the mailing list +address instead. + +The gnus-group-split mail splitting mechanism will behave as if this +address was listed in gnus-group-split Addresses (see below).") + +(gnus-define-group-parameter + to-list + :function-document + "Return GROUP's to-list." + :variable-document + "*Alist of group regexps and correspondent to-lists." + :parameter-type '(gnus-email-address :tag "To List") + :parameter-document "\ +This address will be used when doing a `a' in the group. + +It is totally ignored when doing a followup--except that if it is +present in a news group, you'll get mail group semantics when doing +`f'. + +The gnus-group-split mail splitting mechanism will behave as if this +address was listed in gnus-group-split Addresses (see below).") + +(gnus-define-group-parameter auto-expire :type bool :function gnus-group-auto-expirable-p diff --git a/lisp/message.el b/lisp/message.el index 588ce33..b983eae 100644 --- a/lisp/message.el +++ b/lisp/message.el @@ -3611,10 +3611,13 @@ This sub function is for exclusive use of `message-send-news'." (goto-char (point-min)) (re-search-forward (concat "^" (regexp-quote mail-header-separator) "$")) + (forward-line 1) (while (and - (progn - (end-of-line) - (< (current-column) 80)) + (or (looking-at + mime-edit-tag-regexp) + (let ((p (point))) + (end-of-line) + (< (- (point) p) 80))) (zerop (forward-line 1)))) (or (bolp) (eobp) diff --git a/lisp/mm-util.el b/lisp/mm-util.el index 8f9df0c..2ca0fcd 100644 --- a/lisp/mm-util.el +++ b/lisp/mm-util.el @@ -315,7 +315,7 @@ If the charset is `composition', return the actual one." (defun mm-mime-charset (charset) "Return the MIME charset corresponding to the MULE CHARSET." (if (eq charset 'unknown) - (error "8-bit characters are found in the message, please specify charset.")) + (error "The message contains non-printable characters, please use attachment.")) (if (and (fboundp 'coding-system-get) (fboundp 'get-charset-property)) ;; This exists in Emacs 20. (or