From c2c43c2382db292bfe3cccbccad4386f81f9c8a4 Mon Sep 17 00:00:00 2001 From: Michael Albinus Date: Wed, 29 Aug 2012 14:49:44 +0200 Subject: [PATCH] * eshell/esh-ext.el (eshell-external-command): Do not examine remote shell scripts. See . * net/tramp-sh.el (tramp-remote-path): Add "/sbin" and "/usr/local/sbin". --- lisp/ChangeLog | 9 +++++++++ lisp/eshell/esh-ext.el | 6 +++++- lisp/net/tramp-sh.el | 6 +++--- 3 files changed, 17 insertions(+), 4 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 72eafdca639..bfca3f073f2 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,12 @@ +2012-08-29 Michael Albinus + + * eshell/esh-ext.el (eshell-external-command): Do not examine + remote shell scripts. See + . + + * net/tramp-sh.el (tramp-remote-path): Add "/sbin" and + "/usr/local/sbin". + 2012-08-28 Stefan Monnier * emacs-lisp/cl-lib.el (buffer-string): Fix setter macro (bug#12293). diff --git a/lisp/eshell/esh-ext.el b/lisp/eshell/esh-ext.el index 52df1587d5f..f9f9b1a558f 100644 --- a/lisp/eshell/esh-ext.el +++ b/lisp/eshell/esh-ext.el @@ -209,7 +209,11 @@ causing the user to wonder if anything's really going on..." (setq args (eshell-stringify-list (eshell-flatten-list args))) ;; (if (file-remote-p default-directory) ;; (eshell-remote-command command args)) - (let ((interp (eshell-find-interpreter command))) + (let ((interp (eshell-find-interpreter + command + ;; Do not examine remote shell scripts. + (or (and (stringp command) (file-remote-p command)) + (file-remote-p default-directory))))) (cl-assert interp) (if (functionp (car interp)) (apply (car interp) (append (cdr interp) args)) diff --git a/lisp/net/tramp-sh.el b/lisp/net/tramp-sh.el index 6283188d46a..2c1af3e83fa 100644 --- a/lisp/net/tramp-sh.el +++ b/lisp/net/tramp-sh.el @@ -512,9 +512,9 @@ detected as prompt when being sent on echoing hosts, therefore.") ;; IRIX64: /usr/bin ;;;###tramp-autoload (defcustom tramp-remote-path - '(tramp-default-remote-path "/bin" "/usr/bin" "/usr/sbin" - "/usr/local/bin" "/local/bin" "/local/freeware/bin" "/local/gnu/bin" - "/usr/freeware/bin" "/usr/pkg/bin" "/usr/contrib/bin" + '(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") "List of directories to search for executables on remote host. For every remote host, this variable will be set buffer local, -- 2.39.2