Following solution is used as base to compile current buffer that is a LaTeX
file:
(defun my-run-latex ()
"Save all buffers and run LaTeX on the current master."
(interactive)
(let* ((inhibit-message t)
(TeX-command-force "LaTeX")
(TeX-clean-confirm t)
(TeX-save-query nil)
(master (TeX-master-file))
(process (and (stringp master) (TeX-process master))))
(TeX-save-document master)
(when (and (processp process)
(eq (process-status process) 'run))
(delete-process process))
(TeX-command-master)))
(setq LaTeX-command-style '(("" "%(PDF)%(latex) -shell-escape -interaction=batchmode %S%(PDFout)"))) ;; https://tex.stackexchange.com/a/161303/127048
(add-hook 'LaTeX-mode-hook (λ ()
(TeX-fold-mode 1)))
Here even I have -interaction=batchmode
flag, AucTeX
adds -interaction=nonstopmode
, which force to generated output during latex compilation. I want to suppress the generated compile logs to speed up the build process.
file name *
:
Running `LaTeX' on `eblocbroker' with ``pdflatex -shell-escape -interaction=batchmode -interaction=nonstopmode work.tex''
This is pdfTeX, Version 3.141592653-2.6-1.40.24 (TeX Live 2022) (preloaded format=pdflatex)
\write18 enabled.
entering extended mode
(./work.tex
// generated compile log ...
How can I prevent pdflatex
logs to be created or is there any way to suppress the logs or have lowest verbose outputs?