From: Jim Porter Date: Wed, 10 Jul 2024 00:19:26 +0000 (-0700) Subject: Don't use the Lisp implementation of "kill" in remote Eshell directories X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=1de768821e5cf76c85821f4a57b5537783377368;p=emacs.git Don't use the Lisp implementation of "kill" in remote Eshell directories * lisp/eshell/esh-proc.el (eshell/kill): When in a remote directory, fall back to the external "kill" program (bug#72013). (cherry picked from commit 342998511add79c594a170dc04ecda2f2db0fd36) --- diff --git a/lisp/eshell/esh-proc.el b/lisp/eshell/esh-proc.el index a5e9de79907..f982e2101f5 100644 --- a/lisp/eshell/esh-proc.el +++ b/lisp/eshell/esh-proc.el @@ -206,6 +206,11 @@ This is like `process-live-p', but additionally checks whether Usage: kill [-] | ... Accepts PIDs and process objects. Optionally accept signals and signal names." + ;; The implementation below only supports local PIDs. For remote + ;; connections, fall back to the external "kill" command. + (when (file-remote-p default-directory) + (declare-function eshell-external-command "esh-ext" (command args)) + (throw 'eshell-external (eshell-external-command "kill" args))) ;; If the first argument starts with a dash, treat it as the signal ;; specifier. (let ((signum 'SIGINT))