1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-01-03 10:31:37 -08:00

Revert commit 225ca617b7, and apply another fix

* lisp/minibuffer.el (read-file-name-default): Revert commit
225ca617b7.  (Bug#50976).

* lisp/shell.el (shell): Remove volume letter for remote shell
file name.  (Bug#49229)
This commit is contained in:
Michael Albinus 2021-10-23 15:21:14 +02:00
parent cdbd03345d
commit 8c5fbd712b
2 changed files with 9 additions and 6 deletions

View file

@ -766,12 +766,16 @@ Make the shell buffer the current buffer, and return it.
(called-interactively-p 'any)
(null explicit-shell-file-name)
(null (getenv "ESHELL")))
;; `expand-file-name' shall not add the MS Windows volume letter
;; (Bug#49229).
(setq-local explicit-shell-file-name
(file-local-name
(expand-file-name
(read-file-name "Remote shell path: " default-directory
shell-file-name t shell-file-name
#'file-remote-p)))))
(replace-regexp-in-string
"^[[:alpha:]]:" ""
(file-local-name
(expand-file-name
(read-file-name "Remote shell path: " default-directory
shell-file-name t shell-file-name
#'file-remote-p))))))
;; Rain or shine, BUFFER must be current by now.
(unless (comint-check-proc buffer)