emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] master 048bdc2: Tweak prompt when symlinking in dired


From: Lars Ingebrigtsen
Subject: [Emacs-diffs] master 048bdc2: Tweak prompt when symlinking in dired
Date: Fri, 26 Jul 2019 05:12:11 -0400 (EDT)

branch: master
commit 048bdc2740fbd8eb1378437d909d44db89c48ec1
Author: Lars Ingebrigtsen <address@hidden>
Commit: Lars Ingebrigtsen <address@hidden>

    Tweak prompt when symlinking in dired
    
    * lisp/dired-aux.el (dired-do-create-files): Fix prompt when
    sym/hardlinking (bug#26870).
---
 lisp/dired-aux.el | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/lisp/dired-aux.el b/lisp/dired-aux.el
index 0985019..30a941c 100644
--- a/lisp/dired-aux.el
+++ b/lisp/dired-aux.el
@@ -1898,7 +1898,14 @@ Optional arg HOW-TO determines how to treat the target.
                        (set (make-local-variable 
'minibuffer-default-add-function) nil)
                        (setq minibuffer-default defaults))
                    (dired-mark-read-file-name
-                    (concat (if dired-one-file op1 operation) " %s to: ")
+                     (format "%s %%s %s: "
+                             (if dired-one-file op1 operation)
+                             (if (memq op-symbol '(symlink hardlink))
+                                 ;; Linking operations create links
+                                 ;; from the prompted file name; the
+                                 ;; other operations copy (etc) to the
+                                 ;; prompted file name.
+                                 "from" "to"))
                     target-dir op-symbol arg rfn-list default))))
         (into-dir
           (progn



reply via email to

[Prev in Thread] Current Thread [Next in Thread]