With this change, if :file <filepath> is specified, ruby and python
blindly output a link to <filepath>. Responsibility for creating the
contents in <filepath> lies with the python/ruby code.
Doug Hellmann writes:
> Some calendar systems (Google, Zimbra) handle subscriptions to
> multiple calendars (or to an account) by grouping them under a single
> caldav directory in the calendar tree. org-mac-iCal assumes there is
> only one ics file created per caldav directory, so while it *creates*
> all of the needed merged ics files, it only copies one of them to
> ~/Library/Calendar before importing the contents into the diary.
A "functional-style" source block is one in which the name is followed
immediately by a parenthesised argument. An example is the following
"function", which generates n uniform random numbers:
\#+srcname: rand(n)
\#+begin_src R
runif(n)
\#+end_src
With these changes, such source blocks are passed over to the export
machinery in the following form:
\#+begin_src org-babel-lob
<function-def-keyword> rand(n):
\#+end_src
\#+begin_src R <switches>
<indent>runif(n)
\#+end_src
where <function-def-keyword> is the value of
org-babel-function-def-export-keyword, which defaults to "function",
<switches> are the src block switches that belonged to the original
block, and <indent> is the whitespace indent of the function body, the
width of which is determined by org-babel-function-def-export-indent.
org-babel-lob is a simple major mode responsible for fontification of
the blocks corresponding to the function definition line (as opposed
to the function body).
This adds a new terminal (sixth) element to the list returned from
org-babel-get-src-block-info. It is used when exporting the code of
"functional style" code blocks, i.e. those in which the name of the
block is followed by a parenthesised argument list (or an empty pair
of parentheses).
- org-babel-get-src-block-info returns the name of the block as a new
fifth element.
- org-babel-get-src-block-info incorporates the parenthesised variable
references into the header arg list, with precendence given to
explicit :var references, as before.
- remove function org-babel-get-src-block-name
- remove function org-babel-get-src-block-function-args
org-babel-get-src-block-function-args now returns a list
(lang body params-alist switches srcname)
where, unless a non-nil value for the optional argument is passed,
params-alist contains any :var entries acquired from the parenthesised
argument list following the srcname.
The switches are flags like -n and must *precede* the first colon
after the language (i.e. precede the first header argument). So the
general src block syntax is
\#+begin_src lang <switches> :header1 val1 :header2 val2 ...
...
org-babel-get-src-block-info now returns a list
(lang body params-alist switches)
noweb references which include ()s are now evaluated. It is
possible to pass arguments to the noweb references using the existing
lob argument syntax. So after this commit the following
<<example-block>>
will insert the body of "example-block", and the following
<<example-block()>>
will insert the results of "example-block", and the following
<<example-block(a=9)>>
will insert the results of "example-block" with argument "a" set to
the literal value of 9