Function: org-babel-tangle-publish
org-babel-tangle-publish is a byte-compiled function defined in
ob-tangle.el.gz.
Signature
(org-babel-tangle-publish _ FILENAME PUB-DIR)
Documentation
Tangle FILENAME and place the results in PUB-DIR.
Source Code
;; Defined in /usr/src/emacs/lisp/org/ob-tangle.el.gz
(defun org-babel-tangle-publish (_ filename pub-dir)
"Tangle FILENAME and place the results in PUB-DIR."
(unless (file-exists-p pub-dir)
(make-directory pub-dir t))
(setq pub-dir (file-name-as-directory pub-dir))
;; Rename files to avoid copying to same file when publishing to ./
;; `copy-file' would throw an error when copying file to self.
(mapc (lambda (el) (rename-file el pub-dir t))
(org-babel-tangle-file filename)))