# HG changeset patch # User Richard M. Stallman # Date 795762878 0 # Node ID c5fbb6f272f220040ee77add7d47f84cc68570a7 # Parent d629a0af50ca42b250d66006a44dbcf05f697110 (shell-command): Use *Async Shell Command* for asynchronous commands. Doc fix. diff -r d629a0af50ca -r c5fbb6f272f2 lisp/simple.el --- a/lisp/simple.el Tue Mar 21 02:19:38 1995 +0000 +++ b/lisp/simple.el Tue Mar 21 05:14:38 1995 +0000 @@ -712,8 +712,17 @@ (defun shell-command (command &optional output-buffer) "Execute string COMMAND in inferior shell; display output, if any. + If COMMAND ends in ampersand, execute it asynchronously. -The output appears in the buffer `*Shell Command*'. +The output appears in the buffer `*Async Shell Command*'. + +Otherwise, COMMAND is executed synchronously. The output appears +in the buffer `*Shell Command Output*'. +If the output is one line, it is displayed in the echo area *as well*, +but it is nonetheless available in buffer `*Shell Command Output*', +even though that buffer is not automatically displayed. +If there is no output, or if output is inserted in the current buffer, +then `*Shell Command Output*' is deleted. The optional second argument OUTPUT-BUFFER, if non-nil, says to put the output in some other buffer. @@ -747,7 +756,7 @@ (if (string-match "[ \t]*&[ \t]*$" command) ;; Command ending with ampersand means asynchronous. (let ((buffer (get-buffer-create - (or output-buffer "*Shell-Command*"))) + (or output-buffer "*Asynch Shell Command*"))) (directory default-directory) proc) ;; Remove the ampersand.