Nick Dokos <nicholas.do...@hp.com> writes: > All you have to do is set the variable org-latex-to-pdf-process, > something like this [fn:1] > > (setq org-latex-to-pdf-process > '("pdflatex %f" > "if [ -f %b.sagetex.sage ] ;then sage %b.sagetex.sage ;fi" > "pdflatex %f" > "pdflatex %f"))
Thanks. I was kinda hoping for a solution that uses Elisp rather than offloading it to the shell, but whatever works. In fact, had no one answered, I would have just written a shell script called "pdflatex" that would do the same. I haven't tested it. Suddenly something is wrong with my SageTeX - it was working when I posted this, but not anymore.