[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] Changes to emacs/lisp/mail/rmail.el
From: |
Richard M . Stallman |
Subject: |
[Emacs-diffs] Changes to emacs/lisp/mail/rmail.el |
Date: |
Thu, 17 Mar 2005 19:12:08 -0500 |
Index: emacs/lisp/mail/rmail.el
diff -c emacs/lisp/mail/rmail.el:1.396 emacs/lisp/mail/rmail.el:1.397
*** emacs/lisp/mail/rmail.el:1.396 Wed Feb 9 15:50:37 2005
--- emacs/lisp/mail/rmail.el Fri Mar 18 00:12:08 2005
***************
*** 96,118 ****
:group 'rmail)
(defcustom rmail-movemail-program nil
! "If non-nil, name of program for fetching new mail."
:group 'rmail-retrieve
:type '(choice (const nil) string))
(defcustom rmail-pop-password nil
! "*Password to use when reading mail from POP server. Please, use
rmail-remote-password instead."
:type '(choice (string :tag "Password")
(const :tag "Not Required" nil))
:group 'rmail-obsolete)
(defcustom rmail-pop-password-required nil
! "*Non-nil if a password is required when reading mail from a POP server.
Please, use rmail-remote-password-required instead."
:type 'boolean
:group 'rmail-obsolete)
(defcustom rmail-remote-password nil
! "*Password to use when reading mail from a remote server. This setting is
ignored for mailboxes whose URL already contains a password."
:type '(choice (string :tag "Password")
(const :tag "Not Required" nil))
:set-after '(rmail-pop-password)
--- 96,121 ----
:group 'rmail)
(defcustom rmail-movemail-program nil
! "If non-nil, the file name of the `movemail' program."
:group 'rmail-retrieve
:type '(choice (const nil) string))
(defcustom rmail-pop-password nil
! "*Password to use when reading mail from POP server.
! Please use `rmail-remote-password' instead."
:type '(choice (string :tag "Password")
(const :tag "Not Required" nil))
:group 'rmail-obsolete)
(defcustom rmail-pop-password-required nil
! "*Non-nil if a password is required when reading mail from a POP server.
! Please use rmail-remote-password-required instead."
:type 'boolean
:group 'rmail-obsolete)
(defcustom rmail-remote-password nil
! "*Password to use when reading mail from a remote server.
! This setting is ignored for mailboxes whose URL already contains a password."
:type '(choice (string :tag "Password")
(const :tag "Not Required" nil))
:set-after '(rmail-pop-password)
***************
*** 160,167 ****
(defvar rmail-encoded-remote-password nil)
(defcustom rmail-preserve-inbox nil
! "*Non-nil if incoming mail should be left in the user's inbox,
! rather than deleted, after it is retrieved."
:type 'boolean
:group 'rmail-retrieve)
--- 163,169 ----
(defvar rmail-encoded-remote-password nil)
(defcustom rmail-preserve-inbox nil
! "*Non-nil means leave incoming mail in the user's inbox--don't delete it."
:type 'boolean
:group 'rmail-retrieve)
***************
*** 171,178 ****
:type '(repeat (directory)))
(defun rmail-probe (prog)
! "Determine what flavor of movemail PROG is by executing it with --version
! command line option and analyzing its output."
(with-temp-buffer
(let ((tbuf (current-buffer)))
(buffer-disable-undo tbuf)
--- 173,180 ----
:type '(repeat (directory)))
(defun rmail-probe (prog)
! "Determine what flavor of movemail PROG is.
! We do this by executing it with `--version' and analyzing its output."
(with-temp-buffer
(let ((tbuf (current-buffer)))
(buffer-disable-undo tbuf)
***************
*** 191,200 ****
'emacs))))))
(defun rmail-autodetect ()
! "Determine and return the flavor of `movemail' program in use. If
! rmail-movemail-program is set, use it. Otherwise, look for `movemail'
! in the path constructed by appending rmail-movemail-search-path,
! exec-path and exec-directory."
(if rmail-movemail-program
(rmail-probe rmail-movemail-program)
(catch 'scan
--- 193,202 ----
'emacs))))))
(defun rmail-autodetect ()
! "Determine and return the file name of the `movemail' program.
! If `rmail-movemail-program' is non-nil, use it.
! Otherwise, look for `movemail' in the directories in
! `rmail-movemail-search-path', those in `exec-path', and `exec-directory'."
(if rmail-movemail-program
(rmail-probe rmail-movemail-program)
(catch 'scan
***************
*** 2609,2614 ****
--- 2611,2649 ----
(interactive)
(rmail-show-message rmail-current-message))
+ (defun rmail-unknown-mail-followup-to ()
+ "Handle a \"Mail-Followup-To\" header field with an unknown mailing list.
+ Ask the user whether to add that list name to `mail-mailing-lists'."
+ (save-restriction
+ (rmail-narrow-to-non-pruned-header)
+ (let ((mail-followup-to (mail-fetch-field "mail-followup-to" nil t)))
+ (when mail-followup-to
+ (let ((addresses
+ (split-string
+ (mail-strip-quoted-names mail-followup-to)
+ ",[[:space:]]+" t)))
+ (dolist (addr addresses)
+ (when (and (not (member addr mail-mailing-lists))
+ (not
+ ;; taken from rmailsum.el
+ (string-match
+ (or rmail-user-mail-address-regexp
+ (concat "^\\("
+ (regexp-quote (user-login-name))
+ "\\($\\|@\\)\\|"
+ (regexp-quote
+ (or user-mail-address
+ (concat (user-login-name) "@"
+ (or mail-host-address
+ (system-name)))))
+ "\\>\\)"))
+ addr))
+ (y-or-n-p
+ (format "Add `%s' to `mail-mailing-lists'? "
+ addr)))
+ (customize-save-variable 'mail-mailing-lists
+ (cons addr mail-mailing-lists)))))))))
+
(defun rmail-show-message (&optional n no-summary)
"Show message number N (prefix argument), counting from start of file.
If summary buffer is currently displayed, update current message there also."
***************
*** 2677,2684 ****
(rmail-display-labels)
(if (eq rmail-enable-mime t)
(funcall rmail-show-mime-function)
! (setq rmail-view-buffer rmail-buffer)
! )
(rmail-highlight-headers)
(if transient-mark-mode (deactivate-mark))
(run-hooks 'rmail-show-message-hook)
--- 2712,2720 ----
(rmail-display-labels)
(if (eq rmail-enable-mime t)
(funcall rmail-show-mime-function)
! (setq rmail-view-buffer rmail-buffer))
! (when mail-mailing-lists
! (rmail-unknown-mail-followup-to))
(rmail-highlight-headers)
(if transient-mark-mode (deactivate-mark))
(run-hooks 'rmail-show-message-hook)
***************
*** 3367,3375 ****
(progn (search-forward "\n*** EOOH ***\n")
(beginning-of-line) (point)))))
(setq from (mail-fetch-field "from")
! reply-to (or (mail-fetch-field "reply-to" nil t)
from)
cc (and (not just-sender)
(mail-fetch-field "cc" nil t))
subject (mail-fetch-field "subject")
date (mail-fetch-field "date")
--- 3403,3416 ----
(progn (search-forward "\n*** EOOH ***\n")
(beginning-of-line) (point)))))
(setq from (mail-fetch-field "from")
! reply-to (or (if just-sender
! (mail-fetch-field "mail-reply-to" nil t)
! (mail-fetch-field "mail-followup-to" nil t))
! (mail-fetch-field "reply-to" nil t)
from)
cc (and (not just-sender)
+ ;; mail-followup-to, if given, overrides cc.
+ (not (mail-fetch-field "mail-followup-to" nil t))
(mail-fetch-field "cc" nil t))
subject (mail-fetch-field "subject")
date (mail-fetch-field "date")
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] Changes to emacs/lisp/mail/rmail.el,
Richard M . Stallman <=