annotate lisp/obsolete/vms-pmail.el @ 96766:19a21a87b52a

Change from author without assignment thankfully tiny.
author Glenn Morris <rgm@gnu.org>
date Thu, 17 Jul 2008 16:32:15 +0000
parents 090433f48c5f
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
96523
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
1 ;; -*- no-byte-compile: t -*-
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
2 ;; Not byte compiled because it uses functions that are not part of
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
3 ;; emacs, so it would generate unnecessary warnings.
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
4 ;;; vms-pmail.el --- use Emacs as the editor within VMS mail
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
5
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
6 ;; Copyright (C) 1992, 2001, 2002, 2003, 2004, 2005,
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
7 ;; 2006, 2007, 2008 Free Software Foundation, Inc.
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
8
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
9 ;; Author: Roland B Roberts <roberts@panix.com>
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
10 ;; Maintainer: FSF
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
11 ;; Keywords: vms
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
12
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
13 ;; This file is part of GNU Emacs.
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
14
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
15 ;; GNU Emacs is free software: you can redistribute it and/or modify
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
16 ;; it under the terms of the GNU General Public License as published by
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
17 ;; the Free Software Foundation, either version 3 of the License, or
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
18 ;; (at your option) any later version.
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
19
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
20 ;; GNU Emacs is distributed in the hope that it will be useful,
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
21 ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
22 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
23 ;; GNU General Public License for more details.
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
24
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
25 ;; You should have received a copy of the GNU General Public License
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
26 ;; along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>.
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
27
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
28 ;;; Commentary:
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
29
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
30 ;;; Code:
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
31
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
32 ;;;
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
33 ;;; Quick hack to use emacs as mail editor. There are a *bunch* of
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
34 ;;; changes scattered throughout emacs to make this work, namely:
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
35 ;;; (1) mod to sysdep.c to allow emacs to attach to a process other
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
36 ;;; than the one that originally spawned it.
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
37 ;;; (2) mod to kepteditor.com to define the logical emacs_parent_pid
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
38 ;;; which is what sysdep.c looks for, and define the logical
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
39 ;;; emacs_command_args which contains the command line
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
40 ;;; (3) mod to re-parse command line arguments from emacs_command_args
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
41 ;;; then execute them as though emacs were just starting up.
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
42 ;;;
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
43 (defun vms-pmail-save-and-exit ()
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
44 "Save current buffer and exit Emacs.
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
45 If this Emacs cannot be suspended, you will be prompted about modified
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
46 buffers other than the mail buffer. BEWARE --- suspending Emacs without
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
47 saving your mail buffer causes mail to abort the send (potentially useful
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
48 since the mail buffer is still here)."
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
49 (interactive)
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
50 (basic-save-buffer)
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
51 (if (vms-system-info "LOGICAL" "DONT_SUSPEND_EMACS")
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
52 (progn
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
53 (save-some-buffers)
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
54 (kill-emacs 1))
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
55 (kill-buffer (current-buffer))
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
56 (suspend-emacs)))
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
57
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
58 (defun vms-pmail-abort ()
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
59 "Mark buffer as unmodified and exit Emacs.
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
60 When the editor is exited without saving its buffer, VMS mail does not
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
61 send a message. If you have other modified buffers you will be
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
62 prompted for what to do with them."
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
63 (interactive)
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
64 (if (not (yes-or-no-p "Really abort mail? "))
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
65 (ding)
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
66 (not-modified)
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
67 (if (vms-system-info "LOGICAL" "DONT_SUSPEND_EMACS")
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
68 (progn
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
69 (save-some-buffers)
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
70 (kill-emacs 1))
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
71 (kill-buffer (current-buffer))
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
72 (suspend-emacs))))
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
73
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
74 (defun vms-pmail-setup ()
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
75 "Set up file assuming use by VMS MAIL utility.
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
76 The buffer is put into text-mode, auto-save is turned off and the
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
77 following bindings are established.
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
78
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
79 \\[vms-pmail-save-and-exit] vms-pmail-save-and-exit
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
80 \\[vms-pmail-abort] vms-pmail-abort
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
81
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
82 All other Emacs commands are still available."
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
83 (interactive)
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
84 (auto-save-mode -1)
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
85 (text-mode)
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
86 (let ((default (vms-system-info "LOGICAL" "SYS$SCRATCH"))
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
87 (directory (file-name-directory (buffer-file-name)))
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
88 (filename (file-name-nondirectory (buffer-file-name))))
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
89 (if (string= directory "SYS$SCRATCH:")
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
90 (progn
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
91 (cd default)
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
92 (setq buffer-file-name (concat default filename))))
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
93 (use-local-map (copy-keymap (current-local-map)))
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
94 (local-set-key "\C-c\C-c" 'vms-pmail-save-and-exit)
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
95 (local-set-key "\C-c\C-g" 'vms-pmail-abort)))
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
96
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
97 (defun indicate-mail-reply-text ()
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
98 "Prepares received mail for re-sending by placing >'s on each line."
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
99 (interactive)
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
100 (goto-char (point-min))
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
101 (while (not (eobp))
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
102 (insert ">")
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
103 (beginning-of-line)
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
104 (forward-line 1))
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
105 (set-buffer-modified-p nil)
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
106 (goto-char (point-min)))
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
107
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
108 (defun insert-signature ()
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
109 "Moves to the end of the buffer and inserts a \"signature\" file.
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
110 First try the file indicated by environment variable MAIL$TRAILER.
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
111 If that fails, try the file \"~/.signature\".
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
112 If neither file exists, fails quietly."
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
113 (interactive)
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
114 (goto-char (point-max))
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
115 (newline)
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
116 (if (vms-system-info "LOGICAL" "MAIL$TRAILER")
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
117 (if (file-attributes (vms-system-info "LOGICAL" "MAIL$TRAILER"))
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
118 (insert-file-contents (vms-system-info "LOGICAL" "MAIL$TRAILER"))
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
119 (if (file-attributes "~/.signature")
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
120 (insert-file-contents "~/.signature")))))
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
121
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
122 (provide 'vms-pmail)
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
123
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
124 ;; arch-tag: 336850fc-7812-4663-8e4d-b9c13f47dce1
090433f48c5f * vms-patch.el, vmsproc.el, mail/vms-pmail.el: Move to obsolete dir.
Dan Nicolaescu <dann@ics.uci.edu>
parents:
diff changeset
125 ;;; vms-pmail.el ends here