diff options
author | Shaun Johnson <shaun@slugfest.demon.co.uk> | 2011-03-09 15:32:40 +0000 |
---|---|---|
committer | Eric Schulte <schulte.eric@gmail.com> | 2011-04-15 09:55:22 -0600 |
commit | de63411264893ba877444e46439acf28f7ddcba7 (patch) | |
tree | 2e12250b49596ce2de6eb8561fc4df2de42f466f | |
parent | 60864e851bbd67751299877de4a368c8a78e9824 (diff) | |
download | org-mode-de63411264893ba877444e46439acf28f7ddcba7.tar.gz |
Babel: Stop tangling failing in an indirect buffer
* ob-tangle.el (org-babel-tangle): Make it work in an indirect buffer.
The problem was that the message generated after tangling included the
file name of the current buffer which was nil in an indirect buffer.
TINYCHANGE
-rw-r--r-- | lisp/ob-tangle.el | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lisp/ob-tangle.el b/lisp/ob-tangle.el index b4bd147..5a81f73 100644 --- a/lisp/ob-tangle.el +++ b/lisp/ob-tangle.el @@ -243,7 +243,8 @@ exported source code blocks by language." (org-babel-tangle-collect-blocks lang)) (message "tangled %d code block%s from %s" block-counter (if (= block-counter 1) "" "s") - (file-name-nondirectory (buffer-file-name (current-buffer)))) + (file-name-nondirectory + (buffer-file-name (or (buffer-base-buffer) (current-buffer))))) ;; run `org-babel-post-tangle-hook' in all tangled files (when org-babel-post-tangle-hook (mapc |