* lisp/ob-core.el (org-babel-common-header-args-w-values): Add :post to
the list of header arguments.
(org-babel-execute-src-block): Post process results when the :post
header argument has been supplied.
* doc/org.texi (var): Remove the "Alternate argument syntax" section
from the documentation.
* lisp/ob-core.el (org-babel-src-name-w-name-regexp): Update the regexp
used to match code block names.
(org-babel-get-src-block-info): Remove the code used to parse this
alternate variable specification syntax.
* lisp/ob-core.el (org-babel-temp-file): For remote hosts, modify the prefix
and leave `temporary-file-directory' unchanged.
The reason setting `temporary-file-directory' doesn't work here is
because `make-temp-file' recursively calls itself (indirectly).
Modifying `temporary-file-directly', affects the recursive calls as well,
which results in a "No such file file or directory" error.
The fix is to leave `temporary-file-directory' unaltered, for remote
hosts, and instead modifying the 'prefix' argument to `make-temp-file'
appropriately.
TINYCHANGE
* lisp/ob-core.el (org-babel-confirm-evaluate-answer-no): Dynamically
scoped variable, if bound non-nil the confirmation dialog will not
be initiated and denial of evaluation is assumed.
The new variable `org-babel-confirm-evaluate-answer-no´ can be bound
to suppress the user interaction as is needed for async export, as
discussed in http://thread.gmane.org/gmane.emacs.orgmode/67719
multiple changes to remove overly long lines.
* lisp/ob-core.el (org-babel-execute-src-block): A cond makes it more
clear that we definitely do not execute without user confirmation.
(org-babel-where-is-src-block-result): Overly long line.
* lisp/ob-core.el (org-babel-check-confirm-evaluate): New macro to
establish bindings based on INFO.
* lisp/ob-core.el (org-babel-check-evaluate): New defsubst that checks
if the evaluation of a code block is disabled. Refactors the first
part of the original function `org-babel-confirm-evaluate´.
* lisp/ob-core.el (org-babel-confirm-evaluate): New defsubst that
checks if the user should be queried and returns the answer. Keeps
the second part of the original function `org-babel-confirm-evaluate´.
* lisp/ob-core.el (org-babel-execute-src-block): Do not ask for
confirmation if the cached result is current.
* lisp/ob-core.el (org-babel-confirm-evaluate): Re-implement using
bindings for common subexpressions.
There was a minor bug in the reporting of an aborted evaluation as
"disabled" when no export was happening and eval-no-export was t since
the state of the export was not checked again.
* lisp/ob-core.el (org-babel-call-process-region-original): Change
declaration into definition with nil initial value at the beginning
of the file and drop the later definition. Add comment that the
dynamic scoping of this variable is done for tramp.
Reverting "Fix a typo I introduced while editing Achim's commit 091bf0"
Reverting "ob-core.el: Do not ask for confirmation if cached value is current"
This reverts commit 091bf02514.
* ob-core.el (org-babel-execute-src-block): Do not run
`org-babel-confirm-evaluate´ if source block has a cache and the
cache value is current (there is no evaluation involved in this
case).
* lisp/org.el (org-reverse-string): Add `org-reverse-string' to
reverse a string.
* lisp/org-id.el(org-id-new, org-id-decode): Replace
`org-id-reverse-string' by `org-reverse-string'.
* lisp/ob-core.el(org-babel-trim): Replace `org-babel-reverse-string'
by `org-reverse-string' and declare it.
TINYCHANGE
* add a header-row delimiter to the tables returned from mysql
* add new sql-specific header args for the database connection, and implements them for mysql
* add support for :colnames (mysql only)
* (minor) add an edebug spec to org-babel-result-cond to allow edebugging through it
* add some doc about what header args are used
The syntax of result hashes with times are now as show below.
#+RESULTS[<TIME> HASH]:
* lisp/ob-core.el (org-babel-result-regexp): Simplified regexp given new
time hash layout.
(org-babel-current-result-hash): New match string.
(org-babel-hide-hash): New match string.
(org-babel-where-is-src-block-result): New match string, and inserting
hashes in the new format.
* ob-core.el (org-babel-next-src-block)
(org-babel-previous-src-block): Rewrite using
`org-next-block'.
* org.el (org-next-block, org-previous-block): New navigation
commands.
(org-mode-map): Bind the new commands to C-c C-F and C-c C-B
respectively.
Thanks to Bill White for suggesting this.
* ob-core.el (org-ts-regexp): Remove duplicate defconst'ing.
(org-babel-result-regexp): Don't use `org-ts-regexp', use a
regexp string directly.
This is not the best solution, we should be able to use
`org-ts-regexp' here, but the dependencies makes it hard.
So let's not define org-ts-regexp twice, just use a raw
regexp instead, and add a FIXME warning about this.
suggested by Thomas Alexander Gerds
* lisp/ob-core.el (org-babel-result-regexp): Now matching time stamp as
well.
(org-babel-hash-show-time): Variable controlling the display of time
stamps.
(org-babel-current-result-hash): With hash time stamps.
(org-babel-hide-all-hashes): With hash time stamps.
(org-babel-where-is-src-block-result): With hash time stamps.
* lisp/ob.el: Only use the :wrap argument up to the first space when creating
the #+END_ directive.
Using an option like ":wrap SRC fundamental" was generating and end marker of
"#+END_SRC fundamental", which caused the new exporter to fail to handle to
block properly.
Patch from Michael Gauland.