[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [AUCTeX] set up latexmk as default engine + automatically add flags
From: |
Ivan Andrus |
Subject: |
Re: [AUCTeX] set up latexmk as default engine + automatically add flags for lualatex, xelatex |
Date: |
Wed, 24 Oct 2012 10:05:56 +0200 |
On Oct 22, 2012, at 6:57 PM, Benjamin Slade wrote:
> For orgmode, I have a setup that calls up latexmk and automatically
> provides the proper flags for luatex and xetex based on detection of a
> string in the buffer like "#+LATEX_CMD: lualatex".*
>
> I'm wondering how to:
>
> (1) Add Latexmk as a C-c C-c command for AUCTeX, and set it as default.
Here is what I use (except that I don't actually make Latexmk the default in my
.emacs):
(alist-set 'TeX-expand-list
"%(-PDF)"
(list (lambda ()
(if (and (not TeX-Omega-mode)
(or TeX-PDF-mode TeX-DVI-via-PDFTeX))
"-pdf" "-dvi"))))
(alist-set 'TeX-command-list
"Latexmk" '("latexmk %(-PDF) %s"
TeX-run-TeX nil t
:help "Run Latexmk on file to build everything."))
(setq TeX-command-default "Latexmk")
> (2) Institute something similar which searches the buffer for something
> like "LATEX_CMD: lualatex" and set the flags for running latexmk
> accordingly.
% Local Variables:
% TeX-engine: luatex
% End:
-Ivan