diff options
author | Bastien Guerry <bzg@altern.org> | 2012-03-05 21:10:22 +0100 |
---|---|---|
committer | Bastien Guerry <bzg@altern.org> | 2012-03-05 21:10:22 +0100 |
commit | 0630d89a0c4c40b0f5913fc855632abe0669259e (patch) | |
tree | cfc923d54437ab268dd02dd3b8a5959d05c8559b | |
parent | 2cff2cb159e13b118ab1524d770a2f7204b98638 (diff) | |
parent | 9480a2210ce7383c74d76f94bf933a11f87c5733 (diff) | |
download | org-mode-0630d89a0c4c40b0f5913fc855632abe0669259e.tar.gz |
Merge branch 'maint' of orgmode.org:org-mode
-rw-r--r-- | lisp/ob-table.el | 5 | ||||
-rw-r--r-- | lisp/ob-tangle.el | 8 | ||||
-rw-r--r-- | lisp/ob.el | 4 |
3 files changed, 10 insertions, 7 deletions
diff --git a/lisp/ob-table.el b/lisp/ob-table.el index b9d9504..f636415 100644 --- a/lisp/ob-table.el +++ b/lisp/ob-table.el @@ -75,9 +75,8 @@ results NOTE: by default string variable names are interpreted as references to source-code blocks, to force interpretation of a -cell's value as a string, prefix the identifier with two \"$\"s -rather than a single \"$\" (i.e. \"$$2\" instead of \"$2\" in the -example above. +cell's value as a string, prefix the identifier a \"$\" (e.g., +\"$$2\" instead of \"$2\" or \"$@2$2\" instead of \"@2$2\"). NOTE: it is also possible to pass header arguments to the code block. In this case a table cell should hold the string value of diff --git a/lisp/ob-tangle.el b/lisp/ob-tangle.el index 9b5cacd..86be436 100644 --- a/lisp/ob-tangle.el +++ b/lisp/ob-tangle.el @@ -192,9 +192,11 @@ exported source code blocks by language." (when only-this-block (unless (org-babel-where-is-src-block-head) (error "Point is not currently inside of a code block")) - (unless target-file - (setq target-file - (read-from-minibuffer "Tangle to: " (buffer-file-name)))) + (save-match-data + (unless (or (cdr (assoc :tangle (nth 2 (org-babel-get-src-block-info)))) + target-file) + (setq target-file + (read-from-minibuffer "Tangle to: " (buffer-file-name))))) (narrow-to-region (match-beginning 0) (match-end 0))) (save-excursion (let ((block-counter 0) @@ -2225,6 +2225,8 @@ block but are passed literally to the \"example-block\"." (setq index (point)) (nb-add (with-current-buffer parent-buffer + (save-restriction + (widen) (mapconcat ;; interpose PREFIX between every line #'identity (split-string @@ -2284,7 +2286,7 @@ block but are passed literally to the \"example-block\"." "could not be resolved (see " "`org-babel-noweb-error-langs')")) ""))) - "[\n\r]") (concat "\n" prefix))))) + "[\n\r]") (concat "\n" prefix)))))) (nb-add (buffer-substring index (point-max))))) new-body)) |