diff options
| author | Michael Albinus | 2022-07-02 13:19:04 +0200 |
|---|---|---|
| committer | Michael Albinus | 2022-07-02 13:19:04 +0200 |
| commit | c5aec9b10d709b91a0188b705b653bd2a59fff2d (patch) | |
| tree | ddf966202d02b2c2ad2821b87b91e1823c163b1b | |
| parent | 05d240997aeb6ffe3db21e7f4c8e2f181edc37b6 (diff) | |
| download | emacs-c5aec9b10d709b91a0188b705b653bd2a59fff2d.tar.gz emacs-c5aec9b10d709b91a0188b705b653bd2a59fff2d.zip | |
Preserve connection-local settings in dired
* lisp/dired-aux.el (dired-shell-command):
Preserve connection-local settings. (Bug#56333)
| -rw-r--r-- | lisp/dired-aux.el | 25 |
1 files changed, 13 insertions, 12 deletions
diff --git a/lisp/dired-aux.el b/lisp/dired-aux.el index 095f8001701..c403cc5cbde 100644 --- a/lisp/dired-aux.el +++ b/lisp/dired-aux.el | |||
| @@ -1056,18 +1056,19 @@ Return the result of `process-file' - zero for success." | |||
| 1056 | (dir default-directory)) | 1056 | (dir default-directory)) |
| 1057 | (with-current-buffer (get-buffer-create out-buffer) | 1057 | (with-current-buffer (get-buffer-create out-buffer) |
| 1058 | (erase-buffer) | 1058 | (erase-buffer) |
| 1059 | (let* ((default-directory dir) | 1059 | (let ((default-directory dir) res) |
| 1060 | (res (process-file | 1060 | (with-connection-local-variables |
| 1061 | shell-file-name | 1061 | (setq res (process-file |
| 1062 | nil | 1062 | shell-file-name |
| 1063 | t | 1063 | nil |
| 1064 | nil | 1064 | t |
| 1065 | shell-command-switch | 1065 | nil |
| 1066 | cmd))) | 1066 | shell-command-switch |
| 1067 | (dired-uncache dir) | 1067 | cmd)) |
| 1068 | (unless (zerop res) | 1068 | (dired-uncache dir) |
| 1069 | (pop-to-buffer out-buffer)) | 1069 | (unless (zerop res) |
| 1070 | res)))) | 1070 | (pop-to-buffer out-buffer)) |
| 1071 | res))))) | ||
| 1071 | 1072 | ||
| 1072 | 1073 | ||
| 1073 | ;;; Commands that delete or redisplay part of the dired buffer | 1074 | ;;; Commands that delete or redisplay part of the dired buffer |