I've been a fan of the LaTeXTools plugin for Sublime Text for a while. However, the author recently updated the plugin, and it will no longer build my LaTeX documents. I'm wondering if anyone else has had this problem and knows how to fix it? Here's the full console output that I'm getting:
[Compiling /home/tingley/Dropbox/testtex.tex]
TraditionalBuilder: Invoking latexmk...
COULD NOT COMPILE!
Attempted command:latexmk -cd -e $pdflatex = 'pdflatex -interaction=nonstopmode -synctex=1 %S %O' -f -pdf testtex.tex
Build engine: Traditional Builder
I'm using Sublime Text 3 on Ubuntu 13.10 with TeXLive. I can manually compile the document and generate a PDF with the following command:
pdflatex ~/Dropbox/testtex.tex
I would like to be able to do this easily within Sublime, though. I've already tried running "Update LaTeXTools and migrate settings" as well as removing and re-installing the plugin through package control.
Thank you!
I had the same problem too. I did 2 things that fixed the problem.
After migrating my preferences, I opened:
/"yourUsername"/.config/sublime-text-2/Packages/LaTeXTools/builders/traditionalBuilder.py
and I removed the space after the = and before '%E:
$pdflatex = '%E -interaction=nonstopmode........
in the DEFAULT_COMMAND_LATEXMK.
Also, I changed the file:
/"yourUsername"/.config/sublime-text-2/Packages/LaTeXTools/LaTeXTools.default-settings
specifically in the "Platform settings: adapt as needed for your machine" I changed the "linux" section:
from "texpath" : "/usr/texbin"
to "texpath" : "$PATH:/usr/texbin"
After saving the changes, I went to Preferences->Package Settings->LaTexTools and selected Reconfigure LaTexTools and migrate settings.
Restart Sublime and Ready.
I use sublime-text-2 in Arch Linux but I think the changes will work.
I'm the author of the LaTeXTools plugin. You don't need to edit the traditionalBuilder.py file. There is an option called "command" under "builder_settings" in LaTeXTools.sublime-settings. set the latexmk command there. It's all explained in the README.
BTW, do not touch the LaTeXTools.default-settings file. There's no need, and it will be clobbered next time you update the plugin. Rather, regenerate the settings (Reconfigure LaTeXTools... option) and edit LaTeXTools.sublime-settings in the User directory. Again, the README explains this. Thanks!
For me, changing the compiler option to "simple"
(pdflatex) instead of "traditional"
(latexmk) worked!