ox-latex: Split org-latex-compile into two funs
* lisp/ox-latex.el (org-latex-compile): Split off the postprocessing in `org-latex-compile' into a new function, `org-latex-compile--postprocess'.
This commit is contained in:
parent
18d2f871c2
commit
b84018633e
|
@ -4301,6 +4301,15 @@ produced."
|
|||
(outfile (org-compile-file texfile process "pdf"
|
||||
(format "See %S for details" log-buf-name)
|
||||
log-buf spec)))
|
||||
(org-latex-compile--postprocess outfile log-buf snippet)
|
||||
;; Return output file name.
|
||||
outfile))
|
||||
|
||||
(defun org-latex-compile--postprocess (outfile log-buf &optional snippet)
|
||||
"Process the results of creating OUTFILE via LaTeX compilation.
|
||||
Warnings and errors are collected from LOG-BUF.
|
||||
When SNIPPET is nil and `org-latex-remove-logfiles' non-nil,
|
||||
log files (as specified by `org-latex-logfiles-extensions') are deleted."
|
||||
(unless snippet
|
||||
(when org-latex-remove-logfiles
|
||||
(mapc #'delete-file
|
||||
|
@ -4316,9 +4325,7 @@ produced."
|
|||
(cond
|
||||
((eq warnings 'error) " with errors.")
|
||||
(warnings (concat " with warnings: " warnings))
|
||||
(t "."))))))
|
||||
;; Return output file name.
|
||||
outfile))
|
||||
(t ".")))))))
|
||||
|
||||
(defun org-latex--collect-warnings (buffer)
|
||||
"Collect some warnings from \"pdflatex\" command output.
|
||||
|
|
Loading…
Reference in New Issue