From 92e604d0dc601a2dee27d74180ded99e6ca3029f Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Thu, 28 Mar 2019 14:32:16 -0400 Subject: [PATCH] config/literate: don't tangle file in this session org-babel-tangle-file has reportedly killed config.org buffers, despite them being visited. Since we're not doing anything with the return value, may as well keep it in a separate process. --- modules/config/literate/init.el | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/modules/config/literate/init.el b/modules/config/literate/init.el index 57133cc6d..1062c0f61 100644 --- a/modules/config/literate/init.el +++ b/modules/config/literate/init.el @@ -18,15 +18,13 @@ byte-compiled from.") (when (or force-p (file-newer-than-file-p org +literate-config-cache-file)) (message "Compiling your literate config...") - (or (and (if (fboundp 'org-babel-tangle-file) - (org-babel-tangle-file org nil "emacs-lisp") - ;; We tangle in a separate, blank process because loading it here - ;; would load all of :lang org (very expensive!). - (zerop (call-process - "emacs" nil nil nil - "-q" "--batch" "-l" "ob-tangle" "--eval" - (format "(org-babel-tangle-file %S nil \"emacs-lisp\")" - org)))) + ;; We tangle in a separate, blank process because loading it here would + ;; load all of :lang org (very expensive!). + (or (and (zerop (call-process + "emacs" nil nil nil + "-q" "--batch" "-l" "ob-tangle" "--eval" + (format "(org-babel-tangle-file %S nil \"emacs-lisp\")" + org))) ;; Write the cache file to serve as our mtime cache (with-temp-file +literate-config-cache-file t)) (warn "There was a problem tangling your literate config!"))