emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Caching answer to prompt for code block execution


From: Daniele Nicolodi
Subject: Caching answer to prompt for code block execution
Date: Mon, 9 Nov 2020 17:20:19 +0100
User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.14; rv:68.0) Gecko/20100101 Thunderbird/68.12.1

Hello,

I am trying to use the org-sbe macro to compute values in an org table.
This results in a (well, actually two, see my other recent email to the
mailing list) prompt for execution of the relevant code block. This is
unpractical when there are more than an handful of cells to be evaluated.

I have a couple of ideas for improvement.

First, I think prompting only once for code blocks evaluated multiple
times by org-sbe would make a lot of sense and would make the user
experience much better.

Second, I think it would be nice to have a way to cache the answer to
the code block execution prompt. This could be implemented caching
somewhere the answer keyed with an hash of the content of the code
block. This should not require many changes to the code. The only thing
that is not obvious is how to expire the cache to do not have it grow
unbound.

What do others think of these approaches?

Cheers,
Dan




reply via email to

[Prev in Thread] Current Thread [Next in Thread]