From: Richard M. Stallman Date: Wed, 13 Jun 2001 15:26:29 +0000 (+0000) Subject: (shell-command-on-region): Never kill the *Shell Command Output* buffer. X-Git-Tag: emacs-pretest-21.0.104~283 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=fd344fb75f1e0bca5b208d01b9a04c2ba0ad09b8;p=emacs.git (shell-command-on-region): Never kill the *Shell Command Output* buffer. --- diff --git a/lisp/simple.el b/lisp/simple.el index a58f8003bac..4cde8642cf1 100644 --- a/lisp/simple.el +++ b/lisp/simple.el @@ -1434,9 +1434,10 @@ specifies the value of ERROR-BUFFER." (list t error-file) t) nil shell-command-switch command)) - (let ((shell-buffer (get-buffer "*Shell Command Output*"))) - (and shell-buffer (not (eq shell-buffer (current-buffer))) - (kill-buffer shell-buffer))) +;;; It is rude to delete a buffer which the command is not using. +;;; (let ((shell-buffer (get-buffer "*Shell Command Output*"))) +;;; (and shell-buffer (not (eq shell-buffer (current-buffer))) +;;; (kill-buffer shell-buffer))) ;; Don't muck with mark unless REPLACE says we should. (and replace swap (exchange-point-and-mark))) ;; No prefix argument: put the output in a temp buffer, @@ -1485,8 +1486,7 @@ specifies the value of ERROR-BUFFER." (< 0 (nth 7 (file-attributes error-file)))) "(Shell command %sed with some error output)" "(Shell command %sed with no output)") - (if (equal 0 exit-status) "succeed" "fail")) - (kill-buffer buffer))))) + (if (equal 0 exit-status) "succeed" "fail")))))) (when (and error-file (file-exists-p error-file)) (if (< 0 (nth 7 (file-attributes error-file)))