mirror of
https://git.savannah.gnu.org/git/emacs.git
synced 2024-11-25 07:28:20 +00:00
(comint-dynamic-complete): Expand PATHDIR in call to file-name-completion.
This commit is contained in:
parent
5065f906dc
commit
d49458c44a
@ -1184,8 +1184,15 @@ it just adds completion characters to the end of the filename."
|
||||
(let* ((pathname (comint-match-partial-pathname))
|
||||
(pathdir (file-name-directory pathname))
|
||||
(pathnondir (file-name-nondirectory pathname))
|
||||
(completion (file-name-completion pathnondir
|
||||
(or pathdir default-directory))))
|
||||
(completion (file-name-completion
|
||||
pathnondir
|
||||
;; It is important to expand PATHDIR because
|
||||
;; default-directory might be a handled name, and the
|
||||
;; unexpanded PATHDIR won't necessarily match the
|
||||
;; handler regexp.
|
||||
(if pathdir
|
||||
(expand-file-name pathdir)
|
||||
default-directory))))
|
||||
(cond ((null completion)
|
||||
(message "No completions of %s" pathname)
|
||||
(ding))
|
||||
|
Loading…
Reference in New Issue
Block a user