* pgg-epg.el (pgg-epg-sign-region): Select the signing key matched
[elisp/epg.git] / epa.el
diff --git a/epa.el b/epa.el
index 4269254..aae2313 100644 (file)
--- a/epa.el
+++ b/epa.el
@@ -388,7 +388,13 @@ If SECRET is non-nil, list secret keys instead of public keys."
            (epa-mark)
            (goto-char (point-max))
            (setq names (cdr names)))
-       (epa-insert-keys context nil secret))
+       (if secret
+           (progn
+             (setq point (point))
+             (epa-insert-keys context nil secret)
+             (goto-char point)
+             (epa-mark))
+         (epa-insert-keys context nil nil)))
       (epa-keys-mode)
       (setq epa-exit-buffer-function #'abort-recursive-edit)
       (goto-char (point-min))
@@ -450,10 +456,13 @@ If SECRET is non-nil, list secret keys instead of public keys."
              (cdr (assq (epg-sub-key-algorithm (car pointer))
                         epg-pubkey-algorithm-alist))
              "\n\tCreated: "
-             (epg-sub-key-creation-time (car pointer))
+             (format-time-string "%Y-%m-%d"
+                                 (epg-sub-key-creation-time (car pointer)))
              (if (epg-sub-key-expiration-time (car pointer))
-                 (format "\n\tExpires: %s" (epg-sub-key-expiration-time
-                                            (car pointer)))
+                 (format "\n\tExpires: %s"
+                         (format-time-string "%Y-%m-%d"
+                                             (epg-sub-key-expiration-time
+                                              (car pointer))))
                "")
              "\n\tCapabilities: "
              (mapconcat #'symbol-name
@@ -589,7 +598,7 @@ If no one is selected, default secret key is used.  "
   "Encrypt FILE for RECIPIENTS."
   (interactive
    (list (expand-file-name (read-file-name "File: "))
-        (epa-select-keys (epg-make-context) "Select recipents for encryption.
+        (epa-select-keys (epg-make-context) "Select recipients for encryption.
 If no one is selected, symmetric encryption will be performed.  ")))
   (let ((cipher (concat file (if epa-armor ".asc" ".gpg")))
        (context (epg-make-context)))
@@ -725,7 +734,7 @@ If no one is selected, default secret key is used.  "
 Don't use this command in Lisp programs!"
   (interactive
    (list (region-beginning) (region-end)
-        (epa-select-keys (epg-make-context) "Select recipents for encryption.
+        (epa-select-keys (epg-make-context) "Select recipients for encryption.
 If no one is selected, symmetric encryption will be performed.  ")))
   (save-excursion
     (let ((context (epg-make-context))