]> code.delx.au - gnu-emacs-elpa/commitdiff
ivy.el (ivy-alt-done): Ensure the trailing slash for directories
authorOleh Krehel <ohwoeowho@gmail.com>
Tue, 10 Nov 2015 07:17:34 +0000 (08:17 +0100)
committerOleh Krehel <ohwoeowho@gmail.com>
Tue, 10 Nov 2015 07:19:13 +0000 (08:19 +0100)
* ivy.el (ivy-alt-done): Update.

ivy.el

diff --git a/ivy.el b/ivy.el
index 3e1cd31c61b67ff28bab4997fa2adf04c2549d6c..b117617a5451f1a597d27849232a2229252fc741 100644 (file)
--- a/ivy.el
+++ b/ivy.el
@@ -394,8 +394,10 @@ When ARG is t, exit with current text, ignoring the candidates."
                   (not (equal ivy-text ""))
                   (ignore-errors
                     (file-directory-p
-                     (setq dir (expand-file-name
-                                ivy-text ivy--directory)))))
+                     (setq dir
+                           (file-name-as-directory
+                            (expand-file-name
+                             ivy-text ivy--directory))))))
                  (and
                   (not (string= ivy--current "./"))
                   (cl-plusp ivy--length)