1
0
mirror of https://git.savannah.gnu.org/git/emacs/org-mode.git synced 2024-11-23 07:18:53 +00:00

ob-tangle: don't throw errors when we're not under of a headline

* lisp/ob-tangle.el (org-babel-tangle-collect-blocks): don't throw
  errors when we're not under of a headline
This commit is contained in:
Eric Schulte 2010-08-03 11:20:48 -06:00
parent 23a11da5df
commit 158f5cc726

View File

@ -234,7 +234,9 @@ code blocks by language."
(setq current-heading new-heading))
(setq block-counter (+ 1 block-counter))))
(replace-regexp-in-string "[ \t]" "-"
(nth 4 (org-heading-components))))
(condition-case nil
(nth 4 (org-heading-components))
(error (buffer-file-name)))))
(let* ((link (progn (call-interactively 'org-store-link)
(org-babel-clean-text-properties
(car (pop org-stored-links)))))