changeset 10712:5b86ce0cddb5

(recover-file): Use ordinary `f' to read file name.
author Richard M. Stallman <rms@gnu.org>
date Fri, 10 Feb 1995 06:29:31 +0000
parents 551defaf5ba1
children 65676199c76b
files lisp/files.el
diffstat 1 files changed, 4 insertions(+), 9 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/files.el	Thu Feb 09 09:41:18 1995 +0000
+++ b/lisp/files.el	Fri Feb 10 06:29:31 1995 +0000
@@ -1982,15 +1982,10 @@
 
 (defun recover-file (file)
   "Visit file FILE, but get contents from its last auto-save file."
-  (interactive
-   (let ((prompt-file buffer-file-name)
-	 (file-name nil)
-	 (file-dir nil))
-     (and prompt-file
-	  (setq file-name (file-name-nondirectory prompt-file)
-		file-dir (file-name-directory prompt-file)))
-     (list (read-file-name "Recover file: "
-			       file-dir nil nil file-name))))
+  ;; Actually putting the file name in the minibuffer should be used
+  ;; only rarely.
+  ;; Not just because users often use the default.
+  (interactive "fRecover file: ")
   (setq file (expand-file-name file))
   (if (auto-save-file-name-p (file-name-nondirectory file))
       (error "%s is an auto-save file" file))