emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: "Berry, Charles" <ccberry@ucsd.edu>
To: Kyle Meyer <kyle@kyleam.com>
Cc: Mackenzie Bligh <mackenziebligh@gmail.com>,
	"emacs-orgmode@gnu.org" <emacs-orgmode@gnu.org>
Subject: Re: Contribution of a :confirm-evaluate flag to src blocks
Date: Thu, 18 Jul 2019 21:53:13 +0000	[thread overview]
Message-ID: <8EC8C20C-3E43-4E72-98A7-D9415D4740F6@ucsd.edu> (raw)
In-Reply-To: <87blxrdu8e.fsf@kyleam.com>

Gentlemen,

I think you have stepped onto a slippery slope.

Adding an :eval option that turns off confirmation queries without user intervention defeats the security purpose stated for `org-confirm-babel-evaluate'.

Likewise, adding a new header argument that turns off such checks may have pernicious effects.

A better option IMO is to use existing features of babel to accomplish the end you desire. 

A simple option is to have a src block that let binds org-confirm-babel-evaluate to nil, then navigates to and executes another src block that contains noweb statements that execute other blocks. The user is prompted just once and the global behavior of `org-confirm-babel-evaluate' is unaltered.

There are many ways to achieve this kind of behavior and/or fine tune the prompting behavior with existing babel capabilities.

HTH,

Chuck

p.s. I do not get what is `too crude' about using `org-confirm-babel-evaluate'. Maybe an ECM would help others understand what motivates this judgment.

> On Jul 18, 2019, at 12:21 PM, Kyle Meyer <kyle@kyleam.com> wrote:
> 
> Mackenzie Bligh <mackenziebligh@gmail.com> writes:
> 
>> Do you have any suggestions for the name of such a value?
> 
> I tried to avoid being responsible for a poorly chosen name :]
> 
> "'yes' or 'always'" pairs well with the existing "'no' or 'never'", but
> I suppose that risks users not realizing that it implies not querying.
> Perhaps 'eval-no-query', 'eval-without-query', or just 'without-query'?
> 
> 

  reply	other threads:[~2019-07-18 22:30 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-17 18:30 Contribution of a :confirm-evaluate flag to src blocks Mackenzie Bligh
2019-07-18  4:09 ` Kyle Meyer
2019-07-18 17:10   ` Mackenzie Bligh
2019-07-18 19:21     ` Kyle Meyer
2019-07-18 21:53       ` Berry, Charles [this message]
2019-07-18 22:11         ` Kyle Meyer

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

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=8EC8C20C-3E43-4E72-98A7-D9415D4740F6@ucsd.edu \
    --to=ccberry@ucsd.edu \
    --cc=emacs-orgmode@gnu.org \
    --cc=kyle@kyleam.com \
    --cc=mackenziebligh@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 public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).