[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: & and M-& to run programs asynchronously
From: |
Juri Linkov |
Subject: |
Re: & and M-& to run programs asynchronously |
Date: |
Mon, 25 Aug 2008 22:52:17 +0300 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (x86_64-pc-linux-gnu) |
> I see that the new behaviour for & in dired was added. Could the
> documentation for ! (dired-do-shell-command) mention the way of executing a
> command in background? I think this is important because it is not obvious.
>
> I attach the proposed change; please improve the wording as needed..
> Thanks
>
> --- dired-aux.el 14 ago 2008 20:56:23 +0200 1.179
> +++ dired-aux.el 18 ago 2008 02:13:41 +0200
> @@ -551,6 +551,10 @@
> there's no telling what files COMMAND may have changed.
> Type \\[dired-do-redisplay] to redisplay the marked files.
>
> +Emacs will block until the command ends. To execute the command
> +in background, add `&' to the end of COMMAND, or use
> +\\[dired-do-async-shell-command] instead.
> +
> When COMMAND runs, its working directory is the top-level directory of
> the Dired buffer, so output files usually are created there instead of
> in a subdir.
There is no term "background" in the existing Emacs documentation,
so it is better to use the term "asynchronously" like in the
docstring of `shell-command':
Index: lisp/dired-aux.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/dired-aux.el,v
retrieving revision 1.179
diff -c -r1.179 dired-aux.el
*** lisp/dired-aux.el 31 Jul 2008 17:17:35 -0000 1.179
--- lisp/dired-aux.el 25 Aug 2008 19:48:40 -0000
***************
*** 545,551 ****
normally to the shell, but you must confirm first. To pass `*' by
itself to the shell as a wildcard, type `*\"\"'.
! If COMMAND produces output, it goes to a separate buffer.
This feature does not try to redisplay Dired buffers afterward, as
there's no telling what files COMMAND may have changed.
--- 548,558 ----
normally to the shell, but you must confirm first. To pass `*' by
itself to the shell as a wildcard, type `*\"\"'.
! If COMMAND ends in ampersand, it is executed asynchronously
! and the output appears in the buffer `*Async Shell Command*'
! \(you can also use \\[dired-do-async-shell-command]).
! Otherwise, COMMAND is executed synchronously and the output
! appears in the buffer `*Shell Command Output*'.
This feature does not try to redisplay Dired buffers afterward, as
there's no telling what files COMMAND may have changed.
--
Juri Linkov
http://www.jurta.org/emacs/