Fix completion of extended "..." syntax in eshell

* lisp/eshell/em-cmpl.el (eshell-complete-parse-arguments): Expand
"..." (bug#19626).
This commit is contained in:
Michalis V 2021-08-27 18:46:04 +02:00 committed by Lars Ingebrigtsen
parent e26d628a4e
commit 9224a86319

View file

@ -72,6 +72,7 @@
(require 'esh-mode)
(require 'esh-util)
(require 'em-dirs)
(eval-when-compile
(require 'cl-lib)
@ -377,8 +378,12 @@ to writing a completion function."
(cl-assert (eq (car result) 'quote))
(cadr result))
arg)))
(if (numberp val)
(setq val (number-to-string val)))
(cond ((numberp val)
(setq val (number-to-string val)))
;; expand .../ etc that only eshell understands to
;; standard ../../
((string-match "\\.\\.\\.+/" val)
(setq val (eshell-expand-multiple-dots val))))
(or val "")))
args)
posns)))