2000-12-19 22:00:00 ShengHuo ZHU <zsh@cs.rochester.edu>
authorShengHuo ZHU <zsh@cs.rochester.edu>
Wed, 20 Dec 2000 03:05:26 +0000 (03:05 +0000)
committerShengHuo ZHU <zsh@cs.rochester.edu>
Wed, 20 Dec 2000 03:05:26 +0000 (03:05 +0000)
* gpg.el (defalias): Use eval-and-compile.
(gpg-command-all-arglist): Suggest by Jeff Senn <senn@maya.com>.

contrib/ChangeLog
contrib/gpg.el

index 5e19f99..647125a 100644 (file)
@@ -1,3 +1,8 @@
+2000-12-19 22:00:00  ShengHuo ZHU  <zsh@cs.rochester.edu>
+
+       * gpg.el (defalias): Use eval-and-compile.
+       (gpg-command-all-arglist): Suggest by Jeff Senn <senn@maya.com>.
+
 2000-12-15 00:00:00  ShengHuo ZHU  <zsh@cs.rochester.edu>
 
        * gpg.el (gpg-command-alist): Alist may not be defined.
index b967628..b6ce0dd 100644 (file)
@@ -7,7 +7,7 @@
 ;; Keywords: crypto
 ;; Created: 2000-04-15
 
-;; $Id: gpg.el,v 1.7 2000/12/15 04:50:15 zsh Exp $
+;; $Id: gpg.el,v 1.8 2000/12/15 05:26:35 zsh Exp $
 
 ;; This file is NOT (yet?) part of GNU Emacs.
 
 (eval-when-compile 
   (require 'cl))
 
-(defalias 'gpg-point-at-eol
-  (if (fboundp 'point-at-eol)
-      'point-at-eol
-    'line-end-position))
+(eval-and-compile 
+  (defalias 'gpg-point-at-eol
+    (if (fboundp 'point-at-eol)
+       'point-at-eol
+      'line-end-position)))
 
 ;;;; Customization:
 
@@ -237,6 +238,12 @@ for `gpg-2comp' if you don't have this script, but you'll lose PGP
   :type 'gpg-command-alist
   :group 'gpg-options)
 
+(defcustom gpg-command-all-arglist
+  nil
+  "List of arguments to add to all GPG commands."
+  :tag "All command args"
+  :group 'gpg-options)
+
 (defcustom gpg-command-flag-textmode "--textmode"
   "The flag to indicate canonical text mode to GnuPG."
   :tag "Text mode flag"
@@ -543,7 +550,7 @@ it are replaced by SUBSTITUTIONS.
 SUBSTITIONS is a list of (SYMBOL . SEXP) pairs, where SEXP is either a
 string (which is inserted literally), a list of strings (which are
 inserted as well), or nil, which means to insert nothing."
-  (let (arglist)
+  (let ((arglist (copy-list gpg-command-all-arglist)))
     (while template
       (let* ((templ (pop template))
             (repl (assoc templ substitutions))