From: "Clément Pit--Claudel" <clement.pit@gmail.com>
To: emacs-devel@gnu.org
Cc: tino.calancha@gmail.com
Subject: Re: New optional arg to [async-]shell-command[-on-region]
Date: Wed, 13 Jul 2016 16:29:24 +0200 [thread overview]
Message-ID: <57865044.2020807@gmail.com> (raw)
In-Reply-To: <b767b17f-c2c5-b5ab-d27e-304707f13829@gmail.com>
[-- Attachment #1.1: Type: text/plain, Size: 972 bytes --]
On 2016-07-13 16:09, Tino Calancha wrote:
> I would like to propose a patch adding a new optional argument KEEP
> for commands: `shell-command,' `async-shell-command' and
> `shell-command-on-region'.
This looks like an OK idea to me :) Although you could also make it a defcustom instead of cluttering the call signature.
Some comments below:
> (let ((inhibit-read-only t))
> - (erase-buffer))
> + (or keep (erase-buffer)))
I tend to prefer (unless ...) here.
> +Optional ninth arg KEEP, if non-nil, then the output buffer is
> +not erased before inserting the output."
I think something went wrong with the grammar here.
> - (erase-buffer)))
> + (if keep
> + (goto-char (point-max))
> + (erase-buffer))))
Is this in a save-excursion? If not, is there a way to preserve the point in the target buffer? (Is that desirable?)
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]
next prev parent reply other threads:[~2016-07-13 14:29 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-07-13 14:09 New optional arg to [async-]shell-command[-on-region] Tino Calancha
2016-07-13 14:29 ` Clément Pit--Claudel [this message]
2016-07-13 14:48 ` Tino Calancha
2016-07-13 15:06 ` Yuri Khan
2016-07-13 15:27 ` Tino Calancha
2016-07-13 15:58 ` Clément Pit--Claudel
2016-07-13 16:02 ` Clément Pit--Claudel
2016-07-28 12:53 ` New opt to allow not erase out buffer between shell cmds Tino Calancha
2016-08-24 15:10 ` Clément Pit--Claudel
2016-08-26 6:43 ` Tino Calancha
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=57865044.2020807@gmail.com \
--to=clement.pit@gmail.com \
--cc=emacs-devel@gnu.org \
--cc=tino.calancha@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.