branch: externals/ivy-hydra
commit 2ccda7e4160f547b3858466af10fb5422f8a42ee
Author: bymoz089 <[email protected]>
Commit: Oleh Krehel <[email protected]>
ivy.el (ivy--directory-done): Fix "Host name must not match method ssh"
Fixes #2322
---
ivy.el | 18 ++++++++++--------
1 file changed, 10 insertions(+), 8 deletions(-)
diff --git a/ivy.el b/ivy.el
index 1a02aa3..3a0ea63 100644
--- a/ivy.el
+++ b/ivy.el
@@ -1014,14 +1014,16 @@ contains a single candidate.")
(ivy--cd dir)))
((ivy--directory-enter))
((unless (string= ivy-text "")
- (let ((file (expand-file-name
- (if (> ivy--length 0) (ivy-state-current ivy-last)
ivy-text)
- ivy--directory)))
- (when (ignore-errors (file-exists-p file))
- (if (file-directory-p file)
- (ivy--cd (file-name-as-directory file))
- (ivy-done))
- ivy-text))))
+ (with-no-warnings
+ (let* ((tramp-completion-mode t)
+ (file (expand-file-name
+ (if (> ivy--length 0) (ivy-state-current ivy-last)
ivy-text)
+ ivy--directory)))
+ (when (ignore-errors (file-exists-p file))
+ (if (file-directory-p file)
+ (ivy--cd (file-name-as-directory file))
+ (ivy-done))
+ ivy-text)))))
((or (and (equal ivy--directory "/")
(string-match-p "\\`[^/]+:.*:.*\\'" ivy-text))
(string-match-p "\\`/[^/]+:.*:.*\\'" ivy-text))