[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] master f628569 127/184: Make ivy--magic-file-slash less aggressiv
From: |
Oleh Krehel |
Subject: |
[elpa] master f628569 127/184: Make ivy--magic-file-slash less aggressive |
Date: |
Wed, 16 Oct 2019 13:15:05 -0400 (EDT) |
branch: master
commit f628569fa3600aa0e7ccbf38662d8636a570eb77
Author: Mitchell Plamann <address@hidden>
Commit: Oleh Krehel <address@hidden>
Make ivy--magic-file-slash less aggressive
In counsel-find-file, when the user types "foo", selects the prompt, and
presses "/", the result should be "foo/".
If the directory "foobar" exists, but "foo" does not, typing "foo",
selecting the prompt, and pressing "/" results in "cd"ing to "foobar"
(assuming ivy-magic-slash-non-match-action is
'ivy-magic-slash-non-match-cd-selected). This commit changes
ivy--magic-file-slash to check that the prompt is not selected before
performing the ivy-magic-slash-non-match-cd-selected action.
Fixes #2240
---
ivy.el | 1 +
1 file changed, 1 insertion(+)
diff --git a/ivy.el b/ivy.el
index 05d8803..fc1df4c 100644
--- a/ivy.el
+++ b/ivy.el
@@ -3016,6 +3016,7 @@ Possible choices are
'ivy-magic-slash-non-match-cd-selected,
(and (or (> ivy--index 0)
(= ivy--length 1)
magic)
+ (not (ivy--prompt-selected-p))
(not (equal (ivy-state-current ivy-last) ""))
(file-directory-p (ivy-state-current ivy-last))
(or (eq ivy-magic-slash-non-match-action
- [elpa] master 80c2669 142/184: ivy.el (ivy--alist-set): Work-around emacs-24.3 not having alist-get, (continued)
- [elpa] master 80c2669 142/184: ivy.el (ivy--alist-set): Work-around emacs-24.3 not having alist-get, Oleh Krehel, 2019/10/16
- [elpa] master 8b07572 149/184: ivy.el (ivy-configure): Add :display-transformer-fn, Oleh Krehel, 2019/10/16
- [elpa] master 9da8003 158/184: counsel.el (counsel-M-x): Don't sort by default, Oleh Krehel, 2019/10/16
- [elpa] master 8f08f38 155/184: counsel.el (counsel--grep-last-pos): Refactor from counsel-grep-last-line, Oleh Krehel, 2019/10/16
- [elpa] master 6b40d40 156/184: ivy.el (ivy--occur-press-update-window): Re-use ivy-highlight-grep-commands, Oleh Krehel, 2019/10/16
- [elpa] master 2ed4416 165/184: ivy.el (ivy-configure): Add :exit-codes, Oleh Krehel, 2019/10/16
- [elpa] master 2ce5450 177/184: counsel.el (counsel-find-file): Bind "M-o R" to find-file-read-only, Oleh Krehel, 2019/10/16
- [elpa] master c82b852 174/184: ivy.el (ivy-occur-revert-buffer): Simplify, Oleh Krehel, 2019/10/16
- [elpa] master 8bc23e6 104/184: counsel.el (counsel-compile): delete duplicates, Oleh Krehel, 2019/10/16
- [elpa] master 966525c 118/184: counsel.el (counsel-cd): Fix for counsel-ag, Oleh Krehel, 2019/10/16
- [elpa] master f628569 127/184: Make ivy--magic-file-slash less aggressive,
Oleh Krehel <=
- [elpa] master efdee7a 172/184: swiper.el (swiper--occur-insert-lines): Extract, Oleh Krehel, 2019/10/16