Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Remove Warning When Enabling shell-escape in Lyx

Tags:

latex

tex

lyx

I have enabled minted+pygmentize to highlight my program listings, and since pygmentize is an external program, the shell-escape flag must be enabled on pdflatex in Lyx. Now, every time I compile a document without removing this option in the global settings, I get this warning.

shell-escape warning

The following LaTeX backend has been configured to allow execution of external programs for any document:

pdflatex $$i -shell-escape

This is a dangerous configuration. Please, consider using the support offered by LyX for allowing this privilege only to documents that actually need it, instead.

The dialog indicates that there is some document-specific setting that can enable the shell-escape flag, however I see no such option in the document settings, or anything on Google about this error, save one mail archive that only explains why the dialog appears.

Is there some way to set the shell-escape flag from the latex preamble? Or is there some document setting that allows the shell-escape flag that I have been unable to find?

like image 587
Kylelem62 Avatar asked Oct 27 '25 21:10

Kylelem62


1 Answers

I seemed to have found the answer in that mail archive, which was an alternate proposed dialog text.

Go to Document->Settings->Formats and check "Allow running of external programs." This enables the shell-escape flag for the current document only.

enter image description here

like image 89
Kylelem62 Avatar answered Oct 31 '25 12:10

Kylelem62



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!