Fix bug#71235

* lisp/dired.el (dired-insert-directory): Fix remote case.

* lisp/net/tramp.el (tramp-remote-path): Add "/opt/homebrew/bin".
This commit is contained in:
Michael Albinus 2024-06-02 15:09:44 +02:00
parent 4303e5c9fa
commit a37e812d96
2 changed files with 4 additions and 3 deletions

View file

@ -1710,9 +1710,10 @@ see `dired-use-ls-dired' for more details.")
(cond ((and dir-wildcard (files--use-insert-directory-program-p))
(setq switches (concat "-d " switches))
(let* ((default-directory (car dir-wildcard))
(ls (or (and remotep "ls")
insert-directory-program))
(script (format "%s %s %s"
insert-directory-program
switches (cdr dir-wildcard)))
ls switches (cdr dir-wildcard)))
(sh (or (and remotep "/bin/sh")
(executable-find shell-file-name)
(executable-find "sh")))

View file

@ -1370,7 +1370,7 @@ let-bind this variable."
'(tramp-default-remote-path "/bin" "/usr/bin" "/sbin" "/usr/sbin"
"/usr/local/bin" "/usr/local/sbin" "/local/bin" "/local/freeware/bin"
"/local/gnu/bin" "/usr/freeware/bin" "/usr/pkg/bin" "/usr/contrib/bin"
"/opt/bin" "/opt/sbin" "/opt/local/bin")
"/opt/bin" "/opt/sbin" "/opt/local/bin" "/opt/homebrew/bin")
"List of directories to search for executables on remote host.
For every remote host, this variable will be set buffer local,
keeping the list of existing directories on that host.