annotate lisp/mail/mbox-trunk-annotations/rmailout.el.annotation @ 97958:dae412744e36

* isearch.el (isearch-highlight-regexp): Fix last change, quoting non-alphabetical characters properly.
author Chong Yidong <cyd@stupidchicken.com>
date Wed, 03 Sep 2008 00:01:10 +0000
parents 513ae63d6175
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
97531
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
1 1.65 (pj 15-Jul-01): ;;; rmailout.el --- "RMAIL" mail reader for Emacs: output message to a file
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
2 1.4 (eric 30-May-92):
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
3 1.69 (ttn 06-Aug-05): ;; Copyright (C) 1985, 1987, 1993, 1994, 2001, 2002, 2003, 2004,
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
4 1.79 (miles 08-Jan-08): ;; 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
5 1.9 (eric 22-Jul-92):
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
6 1.6 (eric 15-Jul-92): ;; Maintainer: FSF
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
7 1.8 (eric 17-Jul-92): ;; Keywords: mail
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
8 1.1 (root 22-May-90):
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
9 1.1 (root 22-May-90): ;; This file is part of GNU Emacs.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
10 1.1 (root 22-May-90):
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
11 1.81 (gm 06-May-08): ;; GNU Emacs is free software: you can redistribute it and/or modify
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
12 1.1 (root 22-May-90): ;; it under the terms of the GNU General Public License as published by
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
13 1.81 (gm 06-May-08): ;; the Free Software Foundation, either version 3 of the License, or
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
14 1.81 (gm 06-May-08): ;; (at your option) any later version.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
15 1.1 (root 22-May-90):
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
16 1.1 (root 22-May-90): ;; GNU Emacs is distributed in the hope that it will be useful,
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
17 1.1 (root 22-May-90): ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
18 1.1 (root 22-May-90): ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
19 1.1 (root 22-May-90): ;; GNU General Public License for more details.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
20 1.1 (root 22-May-90):
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
21 1.1 (root 22-May-90): ;; You should have received a copy of the GNU General Public License
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
22 1.81 (gm 06-May-08): ;; along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
23 1.65 (pj 15-Jul-01):
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
24 1.65 (pj 15-Jul-01): ;;; Commentary:
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
25 1.1 (root 22-May-90):
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
26 1.6 (eric 15-Jul-92): ;;; Code:
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
27 1.1 (root 22-May-90):
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
28 1.30 (kwzh 09-Feb-94): (require 'rmail)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
29 1.59 (rms 04-Jan-99): (provide 'rmailout)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
30 1.30 (kwzh 09-Feb-94):
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
31 1.44 (rms 14-Sep-96): ;;;###autoload
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
32 1.49 (rms 03-May-97): (defcustom rmail-output-file-alist nil
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
33 1.2 (rms 24-Dec-90): "*Alist matching regexps to suggested output Rmail files.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
34 1.16 (rms 09-Jul-93): This is a list of elements of the form (REGEXP . NAME-EXP).
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
35 1.21 (roland 14-Oct-93): The suggestion is taken if REGEXP matches anywhere in the message buffer.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
36 1.16 (rms 09-Jul-93): NAME-EXP may be a string constant giving the file name to use,
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
37 1.16 (rms 09-Jul-93): or more generally it may be any kind of expression that returns
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
38 1.49 (rms 03-May-97): a file name as a string."
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
39 1.49 (rms 03-May-97): :type '(repeat (cons regexp
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
40 1.49 (rms 03-May-97): (choice :value ""
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
41 1.49 (rms 03-May-97): (string :tag "File Name")
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
42 1.49 (rms 03-May-97): sexp)))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
43 1.49 (rms 03-May-97): :group 'rmail-output)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
44 1.2 (rms 24-Dec-90):
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
45 1.59 (rms 04-Jan-99): (defun rmail-output-read-rmail-file-name ()
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
46 1.59 (rms 04-Jan-99): "Read the file name to use for `rmail-output-to-rmail-file'.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
47 1.59 (rms 04-Jan-99): Set `rmail-default-rmail-file' to this name as well as returning it."
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
48 1.59 (rms 04-Jan-99): (let ((default-file
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
49 1.59 (rms 04-Jan-99): (let (answer tail)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
50 1.59 (rms 04-Jan-99): (setq tail rmail-output-file-alist)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
51 1.59 (rms 04-Jan-99): ;; Suggest a file based on a pattern match.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
52 1.59 (rms 04-Jan-99): (while (and tail (not answer))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
53 1.59 (rms 04-Jan-99): (save-excursion
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
54 1.63 (gerd 08-May-01): (set-buffer rmail-buffer)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
55 1.59 (rms 04-Jan-99): (goto-char (point-min))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
56 1.59 (rms 04-Jan-99): (if (re-search-forward (car (car tail)) nil t)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
57 1.59 (rms 04-Jan-99): (setq answer (eval (cdr (car tail)))))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
58 1.59 (rms 04-Jan-99): (setq tail (cdr tail))))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
59 1.59 (rms 04-Jan-99): ;; If no suggestions, use same file as last time.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
60 1.59 (rms 04-Jan-99): (expand-file-name (or answer rmail-default-rmail-file)))))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
61 1.59 (rms 04-Jan-99): (let ((read-file
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
62 1.59 (rms 04-Jan-99): (expand-file-name
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
63 1.59 (rms 04-Jan-99): (read-file-name
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
64 1.70 (rfrancoi 24-Sep-05): (concat "Output message to Rmail file (default "
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
65 1.59 (rms 04-Jan-99): (file-name-nondirectory default-file)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
66 1.70 (rfrancoi 24-Sep-05): "): ")
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
67 1.59 (rms 04-Jan-99): (file-name-directory default-file)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
68 1.59 (rms 04-Jan-99): (abbreviate-file-name default-file))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
69 1.59 (rms 04-Jan-99): (file-name-directory default-file))))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
70 1.59 (rms 04-Jan-99): ;; If the user enters just a directory,
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
71 1.59 (rms 04-Jan-99): ;; use the name within that directory chosen by the default.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
72 1.59 (rms 04-Jan-99): (setq rmail-default-rmail-file
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
73 1.59 (rms 04-Jan-99): (if (file-directory-p read-file)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
74 1.59 (rms 04-Jan-99): (expand-file-name (file-name-nondirectory default-file)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
75 1.59 (rms 04-Jan-99): read-file)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
76 1.59 (rms 04-Jan-99): read-file)))))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
77 1.59 (rms 04-Jan-99):
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
78 1.59 (rms 04-Jan-99): (defun rmail-output-read-file-name ()
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
79 1.59 (rms 04-Jan-99): "Read the file name to use for `rmail-output'.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
80 1.59 (rms 04-Jan-99): Set `rmail-default-file' to this name as well as returning it."
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
81 1.59 (rms 04-Jan-99): (let ((default-file
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
82 1.59 (rms 04-Jan-99): (let (answer tail)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
83 1.59 (rms 04-Jan-99): (setq tail rmail-output-file-alist)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
84 1.59 (rms 04-Jan-99): ;; Suggest a file based on a pattern match.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
85 1.59 (rms 04-Jan-99): (while (and tail (not answer))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
86 1.59 (rms 04-Jan-99): (save-excursion
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
87 1.59 (rms 04-Jan-99): (goto-char (point-min))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
88 1.59 (rms 04-Jan-99): (if (re-search-forward (car (car tail)) nil t)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
89 1.59 (rms 04-Jan-99): (setq answer (eval (cdr (car tail)))))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
90 1.59 (rms 04-Jan-99): (setq tail (cdr tail))))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
91 1.59 (rms 04-Jan-99): ;; If no suggestion, use same file as last time.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
92 1.59 (rms 04-Jan-99): (or answer rmail-default-file))))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
93 1.59 (rms 04-Jan-99): (let ((read-file
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
94 1.59 (rms 04-Jan-99): (expand-file-name
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
95 1.59 (rms 04-Jan-99): (read-file-name
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
96 1.70 (rfrancoi 24-Sep-05): (concat "Output message to Unix mail file (default "
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
97 1.59 (rms 04-Jan-99): (file-name-nondirectory default-file)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
98 1.70 (rfrancoi 24-Sep-05): "): ")
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
99 1.59 (rms 04-Jan-99): (file-name-directory default-file)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
100 1.59 (rms 04-Jan-99): (abbreviate-file-name default-file))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
101 1.59 (rms 04-Jan-99): (file-name-directory default-file))))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
102 1.59 (rms 04-Jan-99): (setq rmail-default-file
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
103 1.59 (rms 04-Jan-99): (if (file-directory-p read-file)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
104 1.59 (rms 04-Jan-99): (expand-file-name (file-name-nondirectory default-file)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
105 1.59 (rms 04-Jan-99): read-file)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
106 1.59 (rms 04-Jan-99): (expand-file-name
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
107 1.59 (rms 04-Jan-99): (or read-file (file-name-nondirectory default-file))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
108 1.59 (rms 04-Jan-99): (file-name-directory default-file)))))))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
109 1.59 (rms 04-Jan-99):
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
110 1.77 (dann 25-Nov-07): (declare-function rmail-update-summary "rmailsum" (&rest ignore))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
111 1.77 (dann 25-Nov-07):
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
112 1.55 (rms 16-Aug-98): ;;; There are functions elsewhere in Emacs that use this function;
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
113 1.55 (rms 16-Aug-98): ;;; look at them before you change the calling method.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
114 1.45 (rms 27-Sep-96): ;;;###autoload
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
115 1.61 (fx 24-May-00): (defun rmail-output-to-rmail-file (file-name &optional count stay)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
116 1.1 (root 22-May-90): "Append the current message to an Rmail file named FILE-NAME.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
117 1.1 (root 22-May-90): If the file does not exist, ask if it should be created.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
118 1.1 (root 22-May-90): If file is being visited, the message is appended to the Emacs
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
119 1.1 (root 22-May-90): buffer visiting that file.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
120 1.50 (rms 20-Sep-97): If the file exists and is not an Rmail file, the message is
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
121 1.50 (rms 20-Sep-97): appended in inbox format, the same way `rmail-output' does it.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
122 1.16 (rms 09-Jul-93):
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
123 1.37 (rms 05-May-94): The default file name comes from `rmail-default-rmail-file',
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
124 1.28 (rms 15-Jan-94): which is updated to the name you use in this command.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
125 1.28 (rms 15-Jan-94):
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
126 1.71 (eliz 04-Nov-05): A prefix argument COUNT says to output that many consecutive messages,
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
127 1.61 (fx 24-May-00): starting with the current one. Deleted messages are skipped and don't count.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
128 1.61 (fx 24-May-00):
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
129 1.71 (eliz 04-Nov-05): If the optional argument STAY is non-nil, then leave the last filed
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
130 1.71 (eliz 04-Nov-05): message up instead of moving forward to the next non-deleted message."
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
131 1.13 (rms 11-Jun-93): (interactive
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
132 1.59 (rms 04-Jan-99): (list (rmail-output-read-rmail-file-name)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
133 1.59 (rms 04-Jan-99): (prefix-numeric-value current-prefix-arg)))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
134 1.11 (jimb 14-Feb-93): (or count (setq count 1))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
135 1.3 (jimb 01-Mar-91): (setq file-name
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
136 1.3 (jimb 01-Mar-91): (expand-file-name file-name
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
137 1.27 (rms 15-Jan-94): (file-name-directory rmail-default-rmail-file)))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
138 1.42 (rms 21-Sep-95): (if (and (file-readable-p file-name) (not (mail-file-babyl-p file-name)))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
139 1.16 (rms 09-Jul-93): (rmail-output file-name count)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
140 1.16 (rms 09-Jul-93): (rmail-maybe-set-message-counters)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
141 1.16 (rms 09-Jul-93): (setq file-name (abbreviate-file-name file-name))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
142 1.47 (rms 30-Mar-97): (or (find-buffer-visiting file-name)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
143 1.16 (rms 09-Jul-93): (file-exists-p file-name)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
144 1.16 (rms 09-Jul-93): (if (yes-or-no-p
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
145 1.16 (rms 09-Jul-93): (concat "\"" file-name "\" does not exist, create it? "))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
146 1.16 (rms 09-Jul-93): (let ((file-buffer (create-file-buffer file-name)))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
147 1.1 (root 22-May-90): (save-excursion
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
148 1.16 (rms 09-Jul-93): (set-buffer file-buffer)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
149 1.16 (rms 09-Jul-93): (rmail-insert-rmail-file-header)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
150 1.62 (eliz 11-Mar-01): (let ((require-final-newline nil)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
151 1.62 (eliz 11-Mar-01): (coding-system-for-write
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
152 1.62 (eliz 11-Mar-01): (or rmail-file-coding-system
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
153 1.62 (eliz 11-Mar-01): 'emacs-mule-unix)))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
154 1.16 (rms 09-Jul-93): (write-region (point-min) (point-max) file-name t 1)))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
155 1.16 (rms 09-Jul-93): (kill-buffer file-buffer))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
156 1.16 (rms 09-Jul-93): (error "Output file does not exist")))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
157 1.16 (rms 09-Jul-93): (while (> count 0)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
158 1.16 (rms 09-Jul-93): (let (redelete)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
159 1.16 (rms 09-Jul-93): (unwind-protect
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
160 1.16 (rms 09-Jul-93): (progn
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
161 1.63 (gerd 08-May-01): (set-buffer rmail-buffer)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
162 1.24 (rms 23-Dec-93): ;; Temporarily turn off Deleted attribute.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
163 1.24 (rms 23-Dec-93): ;; Do this outside the save-restriction, since it would
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
164 1.24 (rms 23-Dec-93): ;; shift the place in the buffer where the visible text starts.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
165 1.24 (rms 23-Dec-93): (if (rmail-message-deleted-p rmail-current-message)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
166 1.24 (rms 23-Dec-93): (progn (setq redelete t)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
167 1.24 (rms 23-Dec-93): (rmail-set-attribute "deleted" nil)))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
168 1.16 (rms 09-Jul-93): (save-restriction
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
169 1.16 (rms 09-Jul-93): (widen)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
170 1.16 (rms 09-Jul-93): ;; Decide whether to append to a file or to an Emacs buffer.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
171 1.16 (rms 09-Jul-93): (save-excursion
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
172 1.47 (rms 30-Mar-97): (let ((buf (find-buffer-visiting file-name))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
173 1.16 (rms 09-Jul-93): (cur (current-buffer))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
174 1.16 (rms 09-Jul-93): (beg (1+ (rmail-msgbeg rmail-current-message)))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
175 1.52 (rms 27-May-98): (end (1+ (rmail-msgend rmail-current-message)))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
176 1.52 (rms 27-May-98): (coding-system-for-write
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
177 1.52 (rms 27-May-98): (or rmail-file-coding-system
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
178 1.52 (rms 27-May-98): 'emacs-mule-unix)))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
179 1.16 (rms 09-Jul-93): (if (not buf)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
180 1.40 (rms 17-Nov-94): ;; Output to a file.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
181 1.40 (rms 17-Nov-94): (if rmail-fields-not-to-output
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
182 1.40 (rms 17-Nov-94): ;; Delete some fields while we output.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
183 1.40 (rms 17-Nov-94): (let ((obuf (current-buffer)))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
184 1.40 (rms 17-Nov-94): (set-buffer (get-buffer-create " rmail-out-temp"))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
185 1.40 (rms 17-Nov-94): (insert-buffer-substring obuf beg end)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
186 1.40 (rms 17-Nov-94): (rmail-delete-unwanted-fields)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
187 1.40 (rms 17-Nov-94): (append-to-file (point-min) (point-max) file-name)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
188 1.40 (rms 17-Nov-94): (set-buffer obuf)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
189 1.40 (rms 17-Nov-94): (kill-buffer (get-buffer " rmail-out-temp")))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
190 1.40 (rms 17-Nov-94): (append-to-file beg end file-name))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
191 1.16 (rms 09-Jul-93): (if (eq buf (current-buffer))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
192 1.16 (rms 09-Jul-93): (error "Can't output message to same file it's already in"))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
193 1.16 (rms 09-Jul-93): ;; File has been visited, in buffer BUF.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
194 1.16 (rms 09-Jul-93): (set-buffer buf)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
195 1.16 (rms 09-Jul-93): (let ((buffer-read-only nil)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
196 1.16 (rms 09-Jul-93): (msg (and (boundp 'rmail-current-message)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
197 1.16 (rms 09-Jul-93): rmail-current-message)))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
198 1.16 (rms 09-Jul-93): ;; If MSG is non-nil, buffer is in RMAIL mode.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
199 1.16 (rms 09-Jul-93): (if msg
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
200 1.16 (rms 09-Jul-93): (progn
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
201 1.25 (rms 24-Dec-93): ;; Turn on auto save mode, if it's off in this
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
202 1.25 (rms 24-Dec-93): ;; buffer but enabled by default.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
203 1.25 (rms 24-Dec-93): (and (not buffer-auto-save-file-name)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
204 1.25 (rms 24-Dec-93): auto-save-default
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
205 1.25 (rms 24-Dec-93): (auto-save-mode t))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
206 1.16 (rms 09-Jul-93): (rmail-maybe-set-message-counters)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
207 1.16 (rms 09-Jul-93): (widen)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
208 1.16 (rms 09-Jul-93): (narrow-to-region (point-max) (point-max))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
209 1.16 (rms 09-Jul-93): (insert-buffer-substring cur beg end)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
210 1.16 (rms 09-Jul-93): (goto-char (point-min))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
211 1.16 (rms 09-Jul-93): (widen)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
212 1.16 (rms 09-Jul-93): (search-backward "\n\^_")
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
213 1.16 (rms 09-Jul-93): (narrow-to-region (point) (point-max))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
214 1.40 (rms 17-Nov-94): (rmail-delete-unwanted-fields)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
215 1.16 (rms 09-Jul-93): (rmail-count-new-messages t)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
216 1.24 (rms 23-Dec-93): (if (rmail-summary-exists)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
217 1.24 (rms 23-Dec-93): (rmail-select-summary
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
218 1.24 (rms 23-Dec-93): (rmail-update-summary)))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
219 1.16 (rms 09-Jul-93): (rmail-show-message msg))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
220 1.52 (rms 27-May-98): ;; Output file not in rmail mode => just insert at the end.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
221 1.52 (rms 27-May-98): (narrow-to-region (point-min) (1+ (buffer-size)))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
222 1.52 (rms 27-May-98): (goto-char (point-max))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
223 1.52 (rms 27-May-98): (insert-buffer-substring cur beg end)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
224 1.52 (rms 27-May-98): (rmail-delete-unwanted-fields)))))))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
225 1.16 (rms 09-Jul-93): (rmail-set-attribute "filed" t))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
226 1.16 (rms 09-Jul-93): (if redelete (rmail-set-attribute "deleted" t))))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
227 1.16 (rms 09-Jul-93): (setq count (1- count))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
228 1.16 (rms 09-Jul-93): (if rmail-delete-after-output
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
229 1.66 (pot 04-Feb-03): (unless
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
230 1.61 (fx 24-May-00): (if (and (= count 0) stay)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
231 1.61 (fx 24-May-00): (rmail-delete-message)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
232 1.61 (fx 24-May-00): (rmail-delete-forward))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
233 1.61 (fx 24-May-00): (setq count 0))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
234 1.16 (rms 09-Jul-93): (if (> count 0)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
235 1.66 (pot 04-Feb-03): (unless
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
236 1.61 (fx 24-May-00): (if (not stay) (rmail-next-undeleted-message 1))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
237 1.61 (fx 24-May-00): (setq count 0)))))))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
238 1.16 (rms 09-Jul-93):
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
239 1.45 (rms 27-Sep-96): ;;;###autoload
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
240 1.49 (rms 03-May-97): (defcustom rmail-fields-not-to-output nil
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
241 1.49 (rms 03-May-97): "*Regexp describing fields to exclude when outputting a message to a file."
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
242 1.49 (rms 03-May-97): :type '(choice (const :tag "None" nil)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
243 1.49 (rms 03-May-97): regexp)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
244 1.49 (rms 03-May-97): :group 'rmail-output)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
245 1.40 (rms 17-Nov-94):
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
246 1.40 (rms 17-Nov-94): ;; Delete from the buffer header fields we don't want output.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
247 1.40 (rms 17-Nov-94): ;; NOT-RMAIL if t means this buffer does not have the full header
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
248 1.40 (rms 17-Nov-94): ;; and *** EOOH *** that a message in an Rmail file has.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
249 1.40 (rms 17-Nov-94): (defun rmail-delete-unwanted-fields (&optional not-rmail)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
250 1.66 (pot 04-Feb-03): (if rmail-fields-not-to-output
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
251 1.40 (rms 17-Nov-94): (save-excursion
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
252 1.40 (rms 17-Nov-94): (goto-char (point-min))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
253 1.40 (rms 17-Nov-94): ;; Find the end of the header.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
254 1.40 (rms 17-Nov-94): (if (and (or not-rmail (search-forward "\n*** EOOH ***\n" nil t))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
255 1.40 (rms 17-Nov-94): (search-forward "\n\n" nil t))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
256 1.40 (rms 17-Nov-94): (let ((end (point-marker)))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
257 1.40 (rms 17-Nov-94): (goto-char (point-min))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
258 1.40 (rms 17-Nov-94): (while (re-search-forward rmail-fields-not-to-output end t)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
259 1.40 (rms 17-Nov-94): (beginning-of-line)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
260 1.40 (rms 17-Nov-94): (delete-region (point)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
261 1.40 (rms 17-Nov-94): (progn (forward-line 1) (point)))))))))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
262 1.40 (rms 17-Nov-94):
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
263 1.55 (rms 16-Aug-98): ;;; There are functions elsewhere in Emacs that use this function;
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
264 1.55 (rms 16-Aug-98): ;;; look at them before you change the calling method.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
265 1.45 (rms 27-Sep-96): ;;;###autoload
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
266 1.22 (rms 15-Nov-93): (defun rmail-output (file-name &optional count noattribute from-gnus)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
267 1.32 (rms 03-Apr-94): "Append this message to system-inbox-format mail file named FILE-NAME.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
268 1.71 (eliz 04-Nov-05): A prefix argument COUNT says to output that many consecutive messages,
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
269 1.11 (jimb 14-Feb-93): starting with the current one. Deleted messages are skipped and don't count.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
270 1.71 (eliz 04-Nov-05): When called from lisp code, COUNT may be omitted and defaults to 1.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
271 1.19 (rms 25-Jul-93):
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
272 1.20 (rms 09-Oct-93): If the pruned message header is shown on the current message, then
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
273 1.20 (rms 09-Oct-93): messages will be appended with pruned headers; otherwise, messages
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
274 1.20 (rms 09-Oct-93): will be appended with their original headers.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
275 1.28 (rms 15-Jan-94):
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
276 1.38 (rms 19-May-94): The default file name comes from `rmail-default-file',
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
277 1.28 (rms 15-Jan-94): which is updated to the name you use in this command.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
278 1.20 (rms 09-Oct-93):
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
279 1.19 (rms 25-Jul-93): The optional third argument NOATTRIBUTE, if non-nil, says not
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
280 1.22 (rms 15-Nov-93): to set the `filed' attribute, and not to display a message.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
281 1.22 (rms 15-Nov-93):
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
282 1.22 (rms 15-Nov-93): The optional fourth argument FROM-GNUS is set when called from GNUS."
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
283 1.1 (root 22-May-90): (interactive
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
284 1.59 (rms 04-Jan-99): (list (rmail-output-read-file-name)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
285 1.59 (rms 04-Jan-99): (prefix-numeric-value current-prefix-arg)))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
286 1.11 (jimb 14-Feb-93): (or count (setq count 1))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
287 1.3 (jimb 01-Mar-91): (setq file-name
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
288 1.3 (jimb 01-Mar-91): (expand-file-name file-name
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
289 1.27 (rms 15-Jan-94): (and rmail-default-file
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
290 1.27 (rms 15-Jan-94): (file-name-directory rmail-default-file))))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
291 1.42 (rms 21-Sep-95): (if (and (file-readable-p file-name) (mail-file-babyl-p file-name))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
292 1.16 (rms 09-Jul-93): (rmail-output-to-rmail-file file-name count)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
293 1.63 (gerd 08-May-01): (set-buffer rmail-buffer)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
294 1.20 (rms 09-Oct-93): (let ((orig-count count)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
295 1.20 (rms 09-Oct-93): (rmailbuf (current-buffer))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
296 1.20 (rms 09-Oct-93): (case-fold-search t)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
297 1.20 (rms 09-Oct-93): (tembuf (get-buffer-create " rmail-output"))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
298 1.20 (rms 09-Oct-93): (original-headers-p
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
299 1.22 (rms 15-Nov-93): (and (not from-gnus)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
300 1.66 (pot 04-Feb-03): (save-excursion
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
301 1.22 (rms 15-Nov-93): (save-restriction
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
302 1.22 (rms 15-Nov-93): (narrow-to-region (rmail-msgbeg rmail-current-message) (point-max))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
303 1.22 (rms 15-Nov-93): (goto-char (point-min))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
304 1.22 (rms 15-Nov-93): (forward-line 1)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
305 1.22 (rms 15-Nov-93): (= (following-char) ?0)))))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
306 1.20 (rms 09-Oct-93): header-beginning
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
307 1.66 (pot 04-Feb-03): mail-from mime-version content-type)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
308 1.20 (rms 09-Oct-93): (while (> count 0)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
309 1.55 (rms 16-Aug-98): ;; Preserve the Mail-From and MIME-Version fields
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
310 1.55 (rms 16-Aug-98): ;; even if they have been pruned.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
311 1.22 (rms 15-Nov-93): (or from-gnus
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
312 1.55 (rms 16-Aug-98): (save-excursion
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
313 1.55 (rms 16-Aug-98): (save-restriction
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
314 1.55 (rms 16-Aug-98): (widen)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
315 1.55 (rms 16-Aug-98): (goto-char (rmail-msgbeg rmail-current-message))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
316 1.55 (rms 16-Aug-98): (setq header-beginning (point))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
317 1.55 (rms 16-Aug-98): (search-forward "\n*** EOOH ***\n")
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
318 1.55 (rms 16-Aug-98): (narrow-to-region header-beginning (point))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
319 1.66 (pot 04-Feb-03): (setq mail-from (mail-fetch-field "Mail-From"))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
320 1.66 (pot 04-Feb-03): (unless rmail-enable-mime
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
321 1.66 (pot 04-Feb-03): (setq mime-version (mail-fetch-field "MIME-Version")
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
322 1.66 (pot 04-Feb-03): content-type (mail-fetch-field "Content-type"))))))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
323 1.16 (rms 09-Jul-93): (save-excursion
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
324 1.16 (rms 09-Jul-93): (set-buffer tembuf)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
325 1.16 (rms 09-Jul-93): (erase-buffer)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
326 1.16 (rms 09-Jul-93): (insert-buffer-substring rmailbuf)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
327 1.64 (gerd 06-Jul-01): (when rmail-enable-mime
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
328 1.64 (gerd 06-Jul-01): (if original-headers-p
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
329 1.64 (gerd 06-Jul-01): (delete-region (goto-char (point-min))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
330 1.64 (gerd 06-Jul-01): (if (search-forward "\n*** EOOH ***\n")
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
331 1.64 (gerd 06-Jul-01): (match-end 0)))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
332 1.64 (gerd 06-Jul-01): (goto-char (point-min))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
333 1.64 (gerd 06-Jul-01): (forward-line 2)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
334 1.64 (gerd 06-Jul-01): (delete-region (point-min)(point))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
335 1.64 (gerd 06-Jul-01): (search-forward "\n*** EOOH ***\n")
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
336 1.64 (gerd 06-Jul-01): (delete-region (match-beginning 0)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
337 1.64 (gerd 06-Jul-01): (if (search-forward "\n\n")
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
338 1.64 (gerd 06-Jul-01): (1- (match-end 0)))))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
339 1.64 (gerd 06-Jul-01): (setq buffer-file-coding-system (or rmail-file-coding-system
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
340 1.64 (gerd 06-Jul-01): 'raw-text)))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
341 1.40 (rms 17-Nov-94): (rmail-delete-unwanted-fields t)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
342 1.56 (rms 21-Oct-98): (or (bolp) (insert "\n"))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
343 1.16 (rms 09-Jul-93): (goto-char (point-min))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
344 1.20 (rms 09-Oct-93): (if mail-from
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
345 1.20 (rms 09-Oct-93): (insert mail-from "\n")
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
346 1.20 (rms 09-Oct-93): (insert "From "
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
347 1.20 (rms 09-Oct-93): (mail-strip-quoted-names (or (mail-fetch-field "from")
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
348 1.20 (rms 09-Oct-93): (mail-fetch-field "really-from")
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
349 1.20 (rms 09-Oct-93): (mail-fetch-field "sender")
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
350 1.20 (rms 09-Oct-93): "unknown"))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
351 1.20 (rms 09-Oct-93): " " (current-time-string) "\n"))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
352 1.72 (eliz 21-Jan-06): (when mime-version
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
353 1.72 (eliz 21-Jan-06): (insert "MIME-Version: " mime-version)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
354 1.72 (eliz 21-Jan-06): ;; Some malformed MIME messages set content-type to nil.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
355 1.72 (eliz 21-Jan-06): (when content-type
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
356 1.72 (eliz 21-Jan-06): (insert "\nContent-type: " content-type "\n")))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
357 1.16 (rms 09-Jul-93): ;; ``Quote'' "\nFrom " as "\n>From "
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
358 1.16 (rms 09-Jul-93): ;; (note that this isn't really quoting, as there is no requirement
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
359 1.16 (rms 09-Jul-93): ;; that "\n[>]+From " be quoted in the same transparent way.)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
360 1.41 (kwzh 02-Dec-94): (let ((case-fold-search nil))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
361 1.41 (kwzh 02-Dec-94): (while (search-forward "\nFrom " nil t)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
362 1.41 (kwzh 02-Dec-94): (forward-char -5)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
363 1.41 (kwzh 02-Dec-94): (insert ?>)))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
364 1.19 (rms 25-Jul-93): (write-region (point-min) (point-max) file-name t
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
365 1.19 (rms 25-Jul-93): (if noattribute 'nomsg)))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
366 1.20 (rms 09-Oct-93): (or noattribute
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
367 1.20 (rms 09-Oct-93): (if (equal major-mode 'rmail-mode)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
368 1.20 (rms 09-Oct-93): (rmail-set-attribute "filed" t)))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
369 1.20 (rms 09-Oct-93): (setq count (1- count))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
370 1.22 (rms 15-Nov-93): (or from-gnus
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
371 1.22 (rms 15-Nov-93): (let ((next-message-p
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
372 1.22 (rms 15-Nov-93): (if rmail-delete-after-output
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
373 1.22 (rms 15-Nov-93): (rmail-delete-forward)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
374 1.22 (rms 15-Nov-93): (if (> count 0)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
375 1.22 (rms 15-Nov-93): (rmail-next-undeleted-message 1))))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
376 1.22 (rms 15-Nov-93): (num-appended (- orig-count count)))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
377 1.22 (rms 15-Nov-93): (if (and next-message-p original-headers-p)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
378 1.22 (rms 15-Nov-93): (rmail-toggle-header))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
379 1.22 (rms 15-Nov-93): (if (and (> count 0) (not next-message-p))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
380 1.66 (pot 04-Feb-03): (progn
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
381 1.78 (deego 06-Dec-07): (error "%s"
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
382 1.22 (rms 15-Nov-93): (save-excursion
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
383 1.22 (rms 15-Nov-93): (set-buffer rmailbuf)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
384 1.22 (rms 15-Nov-93): (format "Only %d message%s appended" num-appended
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
385 1.22 (rms 15-Nov-93): (if (= num-appended 1) "" "s"))))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
386 1.22 (rms 15-Nov-93): (setq count 0))))))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
387 1.20 (rms 09-Oct-93): (kill-buffer tembuf))))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
388 1.4 (eric 30-May-92):
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
389 1.46 (rms 30-Mar-97): ;;;###autoload
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
390 1.48 (rms 05-Apr-97): (defun rmail-output-body-to-file (file-name)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
391 1.46 (rms 30-Mar-97): "Write this message body to the file FILE-NAME.
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
392 1.46 (rms 30-Mar-97): FILE-NAME defaults, interactively, from the Subject field of the message."
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
393 1.46 (rms 30-Mar-97): (interactive
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
394 1.46 (rms 30-Mar-97): (let ((default-file
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
395 1.51 (rms 23-May-98): (or (mail-fetch-field "Subject")
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
396 1.51 (rms 23-May-98): rmail-default-body-file)))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
397 1.51 (rms 23-May-98): (list (setq rmail-default-body-file
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
398 1.51 (rms 23-May-98): (read-file-name
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
399 1.51 (rms 23-May-98): "Output message body to file: "
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
400 1.51 (rms 23-May-98): (and default-file (file-name-directory default-file))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
401 1.51 (rms 23-May-98): default-file
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
402 1.51 (rms 23-May-98): nil default-file)))))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
403 1.51 (rms 23-May-98): (setq file-name
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
404 1.51 (rms 23-May-98): (expand-file-name file-name
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
405 1.51 (rms 23-May-98): (and rmail-default-body-file
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
406 1.51 (rms 23-May-98): (file-name-directory rmail-default-body-file))))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
407 1.46 (rms 30-Mar-97): (save-excursion
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
408 1.46 (rms 30-Mar-97): (goto-char (point-min))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
409 1.46 (rms 30-Mar-97): (search-forward "\n\n")
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
410 1.48 (rms 05-Apr-97): (and (file-exists-p file-name)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
411 1.74 (lektu 13-Nov-06): (not (y-or-n-p (format "File %s exists; overwrite? " file-name)))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
412 1.48 (rms 05-Apr-97): (error "Operation aborted"))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
413 1.46 (rms 30-Mar-97): (write-region (point) (point-max) file-name)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
414 1.46 (rms 30-Mar-97): (if (equal major-mode 'rmail-mode)
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
415 1.46 (rms 30-Mar-97): (rmail-set-attribute "stored" t)))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
416 1.46 (rms 30-Mar-97): (if rmail-delete-after-output
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
417 1.46 (rms 30-Mar-97): (rmail-delete-forward)))
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
418 1.46 (rms 30-Mar-97):
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
419 1.80 (monnier 10-Apr-08): ;; arch-tag: 447117c6-1a9a-4b88-aa43-3101b043e3a4
513ae63d6175 Temporary convenience files supporting the Rmail/mbox merge to the
Paul Reilly <pmr@pajato.com>
parents:
diff changeset
420 1.4 (eric 30-May-92): ;;; rmailout.el ends here