summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Schulte <schulte.eric@gmail.com>2010-12-20 18:13:46 -0700
committerDan Davison <dandavison7@gmail.com>2010-12-21 14:19:25 +0000
commit44392f1a410b8b09d6b78c9ae4899b96c2996fa3 (patch)
treeb79170712fe218b8e6358167ab08c151179ea52b
parent4e146a5ac22b0de78b9ae8e6cb2309a632d7a0b7 (diff)
downloadorg-mode-44392f1a410b8b09d6b78c9ae4899b96c2996fa3.tar.gz
documentation of the :file header argument for code blocks
-rw-r--r--doc/org.texi24
1 files changed, 12 insertions, 12 deletions
diff --git a/doc/org.texi b/doc/org.texi
index 2657e46..fa6913d 100644
--- a/doc/org.texi
+++ b/doc/org.texi
@@ -11912,18 +11912,18 @@ inserted as with @code{replace}.
@node file, dir, results, Specific header arguments
@subsubsection @code{:file}
-The header argument @code{:file} is used to specify a path for file output.
-An Org-mode style @code{file:} link is inserted into the buffer as the result
-(see @ref{Link format}). Common examples are graphical output from R,
-gnuplot, ditaa and LaTeX code blocks.
-
-Note that for some languages, including R, gnuplot, LaTeX and ditaa,
-graphical output is sent to the specified file without the file being
-referenced explicitly in the code block. See the documentation for the
-individual languages for details. In contrast, general purpose languages such
-as Python and Ruby require that the code explicitly create output
-corresponding to the path indicated by @code{:file}.
-
+The header argument @code{:file} is used to specify an external file in which
+to save code block results. After code block evaluation an Org-mode style
+@code{[[file:]]} link (see @ref{Link format}) to the file will be inserted
+into the Org-mode buffer. Some languages including R, gnuplot, dot, and
+ditaa provide special handling of the @code{:file} header argument
+automatically wrapping the code block body in the boilerplate code required
+to save output to the specified file. This is often useful for saving
+graphical output of a code block to the specified file.
+
+The argument to @code{:file} should be either a string specifying the path to
+a file, or a list of two strings in which case the first element of the list
+should be the path to a file and the second a description for the link.
@node dir, exports, file, Specific header arguments
@subsubsection @code{:dir} and remote execution