diff options
author | Jim Porter <jporterbugs@gmail.com> | 2022-09-15 12:32:02 -0700 |
---|---|---|
committer | Jim Porter <jporterbugs@gmail.com> | 2022-10-17 18:48:52 -0700 |
commit | fd4992d356a9c4225cb518a6a5309aaa1d0f640b (patch) | |
tree | 68a14f0cd2458bfd153239cc61f2a1bf8bfdd4fb | |
parent | cee1cbfd54375cdece23d4741ced6b0c7091f6d9 (diff) | |
download | emacs-fd4992d356a9c4225cb518a6a5309aaa1d0f640b.tar.gz |
Print the correct $PATH when Eshell's 'which' fails to find a command
* lisp/eshell/esh-cmd.el (eshell/which): Use 'eshell-get-path'
(bug#20008).
-rw-r--r-- | lisp/eshell/esh-cmd.el | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lisp/eshell/esh-cmd.el b/lisp/eshell/esh-cmd.el index c5ceb3ffd17..4a41bbe8fa1 100644 --- a/lisp/eshell/esh-cmd.el +++ b/lisp/eshell/esh-cmd.el @@ -1274,8 +1274,9 @@ be finished later after the completion of an asynchronous subprocess." name) (eshell-search-path name))))) (if (not program) - (eshell-error (format "which: no %s in (%s)\n" - name (getenv "PATH"))) + (eshell-error (format "which: no %s in (%s)\n" + name (string-join (eshell-get-path t) + (path-separator)))) (eshell-printn program))))) (put 'eshell/which 'eshell-no-numeric-conversions t) |