expand-file-name
authorueno <ueno>
Mon, 17 Apr 2006 02:46:07 +0000 (02:46 +0000)
committerueno <ueno>
Mon, 17 Apr 2006 02:46:07 +0000 (02:46 +0000)
epa-dired.el
epa.el

index 74c3cff..4c1490a 100644 (file)
@@ -44,7 +44,7 @@
   (interactive)
   (let ((file-list (dired-get-marked-files)))
     (while file-list
-      (epa-decrypt-file (car file-list))
+      (epa-decrypt-file (expand-file-name (car file-list)))
       (setq file-list (cdr file-list)))
     (revert-buffer)))
 
@@ -53,7 +53,7 @@
   (interactive)
   (let ((file-list (dired-get-marked-files)))
     (while file-list
-      (epa-verify-file (car file-list))
+      (epa-verify-file (expand-file-name (car file-list)))
       (setq file-list (cdr file-list)))
     (revert-buffer)))
 
@@ -72,7 +72,7 @@
   (let ((file-list (dired-get-marked-files)))
     (while file-list
       (epa-encrypt-file
-       (car file-list)
+       (expand-file-name (car file-list))
        (mapcar (lambda (key)
                 (epg-sub-key-id
                  (car (epg-key-sub-key-list key))))
diff --git a/epa.el b/epa.el
index 100e02d..8e23cd5 100644 (file)
--- a/epa.el
+++ b/epa.el
 (defun epa-decrypt-file (file)
   (interactive "fFile: ")
   (let* ((default-name (file-name-sans-extension file))
-        (plain (read-file-name
-                (concat "To file (default "
-                        (file-name-nondirectory default-name)
-                        ") ")
-                (file-name-directory default-name)
-                default-name))
+        (plain (expand-file-name
+                (read-file-name
+                 (concat "To file (default "
+                         (file-name-nondirectory default-name)
+                         ") ")
+                 (file-name-directory default-name)
+                 default-name)))
         (context (epg-make-context)))
     (message "Decrypting %s..." (file-name-nondirectory file))
     (epg-decrypt-file context file plain)