[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] master d3c8028 023/348: ivy.el (ivy--sorted-files): Add a safety
From: |
Oleh Krehel |
Subject: |
[elpa] master d3c8028 023/348: ivy.el (ivy--sorted-files): Add a safety work-around |
Date: |
Sat, 8 Apr 2017 11:03:16 -0400 (EDT) |
branch: master
commit d3c802883f904519bf77c70721f6541957c07967
Author: Oleh Krehel <address@hidden>
Commit: Oleh Krehel <address@hidden>
ivy.el (ivy--sorted-files): Add a safety work-around
It can happen that (all-completions "" 'read-file-name-internal) may
fail on systems with symlinks. I think it's related to the file
functions trying to compute occupied space. In any case, a plain
`directory-files' is roughly the equivalent and is less likely to fail.
---
ivy.el | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/ivy.el b/ivy.el
index eb6fe5d..8e03cc1 100644
--- a/ivy.el
+++ b/ivy.el
@@ -1232,7 +1232,10 @@ like.")
"Return the list of files in DIR.
Directories come first."
(let* ((default-directory dir)
- (seq (all-completions "" 'read-file-name-internal))
+ (seq (condition-case nil
+ (all-completions "" 'read-file-name-internal)
+ (error
+ (directory-files dir))))
sort-fn)
(if (equal dir "/")
seq
- [elpa] master fe93cc6 084/348: counsel.el (counsel-M-x): Fix interaction with repeat, (continued)
- [elpa] master fe93cc6 084/348: counsel.el (counsel-M-x): Fix interaction with repeat, Oleh Krehel, 2017/04/08
- [elpa] master aaad354 088/348: counsel.el (counsel-find-file): Switch directory with "M-o b", Oleh Krehel, 2017/04/08
- [elpa] master e38b23c 091/348: Make counsel-ag extensible, Oleh Krehel, 2017/04/08
- [elpa] master 4dbd8c3 090/348: counsel.el (counsel-semantic): Fix let paren, Oleh Krehel, 2017/04/08
- [elpa] master 2e3cd39 099/348: Support custom command for counsel-git, Oleh Krehel, 2017/04/08
- [elpa] master 94e22bf 096/348: counsel.el (counsel-describe-face): New command, Oleh Krehel, 2017/04/08
- [elpa] master a627164 092/348: Mention that ivy-format-function is the variable described, Oleh Krehel, 2017/04/08
- [elpa] master 0d77775 103/348: README.md: Add a FAQ section, Oleh Krehel, 2017/04/08
- [elpa] master 17b59b2 105/348: Documenting how to generate texinfo, Oleh Krehel, 2017/04/08
- [elpa] master ed61b04 016/348: Fix problems introduced by "(ivy--filter): Recompute index after sort", Oleh Krehel, 2017/04/08
- [elpa] master d3c8028 023/348: ivy.el (ivy--sorted-files): Add a safety work-around,
Oleh Krehel <=
- [elpa] master 4a2f0d4 026/348: Remove needless code, Oleh Krehel, 2017/04/08
- [elpa] master 12145d7 030/348: ivy.el (ivy-completion-in-region-action): Remove string props, Oleh Krehel, 2017/04/08
- [elpa] master 899c2aa 017/348: doc/ivy.org: Mention "/sudo:", Oleh Krehel, 2017/04/08
- [elpa] master c24a372 006/348: doc/Changelog.org: Fix some CUSTOM_ID, Oleh Krehel, 2017/04/08
- [elpa] master 5820db3 029/348: ivy.el (ivy--reset-state): Fix last commit, Oleh Krehel, 2017/04/08
- [elpa] master bc9e17a 033/348: ivy.el (ivy--reset-state): Prevent (expand-file-name nil), Oleh Krehel, 2017/04/08
- [elpa] master 12e35d0 037/348: counsel.el (counsel-bookmark): Add with-ivy-window, Oleh Krehel, 2017/04/08
- [elpa] master 85dc501 005/348: doc/Changelog.org: Add CUSTOM_ID to releases 0.6.0 and 0.7.0, Oleh Krehel, 2017/04/08
- [elpa] master 5826c86 035/348: ivy.el (ivy--reset-state): Add workaround for dired-do-copy, Oleh Krehel, 2017/04/08
- [elpa] master f57e2fb 039/348: ivy.el (ivy-immediate-done): Update docstring, Oleh Krehel, 2017/04/08