From: "Thomas S. Dye" <tsd@tsdye.com>
To: Org Mode <emacs-orgmode@gnu.org>
Subject: :cache documentation patch
Date: Sat, 1 Jan 2011 11:33:35 -1000 [thread overview]
Message-ID: <C70BE355-B685-496A-A627-EE7B84938EE0@tsdye.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 105 bytes --]
Aloha all,
The attached patch documents the behavior of the :cache header argument.
All the best,
Tom
[-- Attachment #2: babel-cache-doc.patch --]
[-- Type: application/octet-stream, Size: 1063 bytes --]
Changes in HEAD
Modified doc/org.texi
diff --git a/doc/org.texi b/doc/org.texi
index f324d04..35e79b7 100644
--- a/doc/org.texi
+++ b/doc/org.texi
@@ -12150,6 +12150,30 @@ executions of the code block. If the code block has not
changed since the last time it was evaluated, it will not be re-evaluated.
@end itemize
+Code block caches notice if the value of a variable argument
+to the code block has changed. If this is the case, the cache is
+invalidated and the code block is re-run. In the following example,
+@code{caller} will not be re-run unless the results of @code{random} have
+changed since it was last run.
+
+@example
+ #+srcname: random
+ #+begin_src R :cache yes
+ runif(1)
+ #+end_src
+
+ #+results[a2a72cd647ad44515fab62e144796432793d68e1]: random
+ 0.4659510825295
+
+ #+srcname: caller
+ #+begin_src emacs-lisp :var x=random :cache yes
+ x
+ #+end_src
+
+ #+results[bec9c8724e397d5df3b696502df3ed7892fc4f5f]: caller
+ 0.254227238707244
+@end example
+
@node sep, hlines, cache, Specific header arguments
@subsubsection @code{:sep}
[-- Attachment #3: Type: text/plain, Size: 1 bytes --]
[-- Attachment #4: Type: text/plain, Size: 201 bytes --]
_______________________________________________
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode
next reply other threads:[~2011-01-01 21:33 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-01-01 21:33 Thomas S. Dye [this message]
2011-01-05 16:27 ` :cache documentation patch Eric Schulte
2011-01-05 18:02 ` Christian Moe
2011-01-06 4:49 ` Eric Schulte
2011-01-05 18:32 ` Thomas S. Dye
2011-01-06 4:47 ` Eric Schulte
2011-01-06 7:45 ` Thomas S. Dye
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=C70BE355-B685-496A-A627-EE7B84938EE0@tsdye.com \
--to=tsd@tsdye.com \
--cc=emacs-orgmode@gnu.org \
/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).