tweak(literate): clear the tangle output buffer

While this is a hidden buffer, it's raised when an error occurs. In such
situations, it can be a little confusing to see the result of every
tangle to date instead of just the last tangle. It's easy enough to
simple clear the buffer at the start of the tangle process.
This commit is contained in:
TEC 2022-09-20 22:11:14 +08:00 committed by Henrik Lissner
parent 028de9483f
commit e2608cbdd5

View file

@ -68,7 +68,10 @@
+literate-tangle--async-proc +literate-tangle--async-proc
;; See `+literate-tangle--sync' for an explanation of the (progn ...) below. ;; See `+literate-tangle--sync' for an explanation of the (progn ...) below.
(start-process "tangle-config" (start-process "tangle-config"
(with-current-buffer
(get-buffer-create " *tangle config*") (get-buffer-create " *tangle config*")
(erase-buffer)
(current-buffer))
"emacs" "--batch" "emacs" "--batch"
"-L" (file-name-directory (locate-library "org")) "-L" (file-name-directory (locate-library "org"))
"--load" (doom-path doom-core-dir "doom") "--load" (doom-path doom-core-dir "doom")