Merge branch 'maint'
This commit is contained in:
commit
c78bb69a11
|
@ -271,7 +271,20 @@ used to limit the exported source code blocks by language."
|
||||||
(and (file-exists-p file-name)
|
(and (file-exists-p file-name)
|
||||||
(not (member file-name (mapcar #'car path-collector)))
|
(not (member file-name (mapcar #'car path-collector)))
|
||||||
(delete-file file-name))
|
(delete-file file-name))
|
||||||
;; drop source-block to file
|
;; Drop source-block to file. Preserve local
|
||||||
|
;; file variables set in original Org buffer so
|
||||||
|
;; that `org-babel-spec-to-string' doesn't
|
||||||
|
;; ignore them.
|
||||||
|
(let ((org-babel-tangle-use-relative-file-links
|
||||||
|
org-babel-tangle-use-relative-file-links)
|
||||||
|
(org-babel-tangle-uncomment-comments
|
||||||
|
org-babel-tangle-uncomment-comments)
|
||||||
|
(org-babel-tangle-comment-format-beg
|
||||||
|
org-babel-tangle-comment-format-beg)
|
||||||
|
(org-src-preserve-indentation
|
||||||
|
org-src-preserve-indentation)
|
||||||
|
(org-babel-tangle-comment-format-end
|
||||||
|
org-babel-tangle-comment-format-end))
|
||||||
(with-temp-buffer
|
(with-temp-buffer
|
||||||
(when (fboundp lang-f) (ignore-errors (funcall lang-f)))
|
(when (fboundp lang-f) (ignore-errors (funcall lang-f)))
|
||||||
(when (and she-bang (not (member file-name she-banged)))
|
(when (and she-bang (not (member file-name she-banged)))
|
||||||
|
@ -289,7 +302,7 @@ used to limit the exported source code blocks by language."
|
||||||
(= (point) (point-min)))
|
(= (point) (point-min)))
|
||||||
(insert "\n"))
|
(insert "\n"))
|
||||||
(insert content)
|
(insert content)
|
||||||
(write-region nil nil file-name))))
|
(write-region nil nil file-name)))))
|
||||||
;; if files contain she-bangs, then make the executable
|
;; if files contain she-bangs, then make the executable
|
||||||
(when she-bang
|
(when she-bang
|
||||||
(unless tangle-mode (setq tangle-mode #o755)))
|
(unless tangle-mode (setq tangle-mode #o755)))
|
||||||
|
|
Loading…
Reference in New Issue