mava / Nova-LaTeX

LaTeX Support for Nova
https://extensions.panic.com/extensions/info.varisco/info.varisco.LaTeX/
MIT License
3 stars 0 forks source link

--shell-escape option #8

Open jblechinger opened 2 years ago

jblechinger commented 2 years ago

Hello, i would need an option to set the flag '-shell-escape'.

In Texshop everything works fine when i add the flags described here:

https://stackoverflow.com/questions/28039856/how-do-i-add-the-shell-escape-option-in-texshop

But i cant do that in your ext. Or i dont know how..

greets!

mava commented 2 years ago

Thanks for the comment, and sorry for the late reply. Currently the extension doesn’t provide this option, but I’ll consider adding it.

Generally, though, I think it’s best to set this kind of options independently of the editor/extension being used — see second paragraph here. For example (with apologies if you already know this), you can always enable --shell-escape by having a file called .latexmkrc in your home directory containing the following line:

set_tex_cmds('--shell-escape %O %S');

(or put the .latexmkrc file in the project folder if you don’t want to enable --shell-escape globally). Then this will work with Nova LaTeX and with any other editor/extension using latexmk. Does this make sense?

jblechinger commented 2 years ago

Thanks for your quick reply!

Im very new with latex so i just try to figure things out. I red about the .latexmkrc file and i also read that --shell-escape could potentially cause security issues. So i decided to try out another latex template i found on github. (where i dont need this setting)

I didnt know that you can create a .latexmkrc file in projects. Thanks for that information!

Thanks for your help your extension really helped me finalize my project!

mava commented 2 years ago

Happy to hear that. Thank you!