aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard M. Stallman1995-03-21 05:14:38 +0000
committerRichard M. Stallman1995-03-21 05:14:38 +0000
commitd382f61045e7fdd00dea62e50e2cdfa7df03d869 (patch)
treed5cc4268303d722d65aa0f5bc0d2cc48f29fdcc9
parent806cba9c00030e0d9b955de1617238f91f8182ba (diff)
downloademacs-d382f61045e7fdd00dea62e50e2cdfa7df03d869.tar.gz
emacs-d382f61045e7fdd00dea62e50e2cdfa7df03d869.zip
(shell-command): Use *Async Shell Command* for
asynchronous commands. Doc fix.
-rw-r--r--lisp/simple.el13
1 files changed, 11 insertions, 2 deletions
diff --git a/lisp/simple.el b/lisp/simple.el
index 418cba339bf..922912bd3e3 100644
--- a/lisp/simple.el
+++ b/lisp/simple.el
@@ -712,8 +712,17 @@ then call `undo-more' one or more times to undo them."
712 712
713(defun shell-command (command &optional output-buffer) 713(defun shell-command (command &optional output-buffer)
714 "Execute string COMMAND in inferior shell; display output, if any. 714 "Execute string COMMAND in inferior shell; display output, if any.
715
715If COMMAND ends in ampersand, execute it asynchronously. 716If COMMAND ends in ampersand, execute it asynchronously.
716The output appears in the buffer `*Shell Command*'. 717The output appears in the buffer `*Async Shell Command*'.
718
719Otherwise, COMMAND is executed synchronously. The output appears
720in the buffer `*Shell Command Output*'.
721If the output is one line, it is displayed in the echo area *as well*,
722but it is nonetheless available in buffer `*Shell Command Output*',
723even though that buffer is not automatically displayed.
724If there is no output, or if output is inserted in the current buffer,
725then `*Shell Command Output*' is deleted.
717 726
718The optional second argument OUTPUT-BUFFER, if non-nil, 727The optional second argument OUTPUT-BUFFER, if non-nil,
719says to put the output in some other buffer. 728says to put the output in some other buffer.
@@ -747,7 +756,7 @@ In either case, the output is inserted after point (leaving mark after it)."
747 (if (string-match "[ \t]*&[ \t]*$" command) 756 (if (string-match "[ \t]*&[ \t]*$" command)
748 ;; Command ending with ampersand means asynchronous. 757 ;; Command ending with ampersand means asynchronous.
749 (let ((buffer (get-buffer-create 758 (let ((buffer (get-buffer-create
750 (or output-buffer "*Shell-Command*"))) 759 (or output-buffer "*Asynch Shell Command*")))
751 (directory default-directory) 760 (directory default-directory)
752 proc) 761 proc)
753 ;; Remove the ampersand. 762 ;; Remove the ampersand.