GNU bug report logs -
#50732
28.0.50; project-find-dir: blank line in fido-vertical-mode
Previous Next
Full log
View this message in rfc822 format
Hi!
On 22.09.2021 11:23, Manuel Uberti wrote:
> This is a quick recipe:
>
> - emacs -Q
> - M-x fido-vertical-mode RET
> - C-x p d
> - choose a project (I picked my .emacs.d directory)
> - there is a blank line between the prompt and the list of candidates
> - see attached screenshot for details
First of all, it's easy to fix:
diff --git a/lisp/progmodes/project.el b/lisp/progmodes/project.el
index ebd21d4b60..028de4bbdf 100644
--- a/lisp/progmodes/project.el
+++ b/lisp/progmodes/project.el
@@ -943,7 +943,8 @@ project-find-dir
;; `project-files-filtered', and see
;; https://stackoverflow.com/a/50685235/615245 for possible
;; implementation.
- (all-dirs (mapcar #'file-name-directory all-files))
+ (all-dirs (delete (expand-file-name (project-root project))
+ (mapcar #'file-name-directory all-files)))
(dir (funcall project-read-file-name-function
"Dired"
;; Some completion UIs show duplicates.
But should it be changed? It seems, while "" is a valid choice (which
leads to visiting the root directory), without it in the completions set
fido-vertical-mode doesn't easily allow you to select such option.
Whereas the default completion UI does.
(Ivy has the same problem, except it never shows "", without or without
the patch, so I'm fine with either).
This bug report was last modified 3 years and 237 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.