I am working on a .tex file inside Visual Studio Code with the Latex Workshop extension installed. I get following error message when I want Latex to compile .svg files for me, following this post

You didn't enable `shell escape' (or `write18')

I tried to add '--shell-escape', '-shell-escape', '-enable-write18' to the arguments that are passed to the pdflatex tool in my settings.json with no effect...

"latex-workshop.latex.tools": [
        "name": "pdflatex",
        "command": "pdflatex",
        "args": [
        "env": {}
        "name": "bibtex",
        "command": "bibtex",
        "args": [
        "env": {}
  • move --shell-escape to be before %DOC% with the other options like -file0line-error – David Carlisle Nov 15 '19 at 21:05
  • tried it, the error remains – shintobi Nov 15 '19 at 21:16
  • well on the commandline you want pdflatex -interaction=nonstopmode --shell-escape myfile.tex the filename has to come last. Show the form you used I assume you need a comma between the arguments, looking at your existing setup – David Carlisle Nov 15 '19 at 21:18
  • like this? magic argument settings – shintobi Nov 15 '19 at 21:26
  • that image looks wrong you have the filename diplom.tex and the placeholder %DOC% which I assume expands to the filename again – David Carlisle Nov 15 '19 at 21:29

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.