Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I add the -shell-escape option in TexShop

Tags:

macos

latex

I am using the minted.sty package and it is requiring that I use the -shell-escape option during latex/xelatex compile. I can do that over the console/terminal. However, I wish to add this option into TexShop. I am prior user of WinEdit on Windows but have recently switched to Mac and TexShop, so don't know how to do it?

Here is the console output:

Package ifplatform Warning: 
shell escape is disabled, so I can only detect \ifwindows.
))
! Package minted Error: You must invoke LaTeX with the -shell-escape  flag.

See the minted package documentation for explanation.
Type  H <return>  for immediate help.
...                                              

l.54 \makeatletter
like image 731
Manish Kochhal Avatar asked Jan 20 '15 07:01

Manish Kochhal


People also ask

Is MacTeX the same as TeXShop?

While TeX Live is designed to be cross-platform (running on Unix, macOS, and Windows), MacTeX includes Mac-specific utilities and front-ends (such as TeXShop and BibDesk).

How do I make a TeXShop pdf?

Even easier, you can drag across a section of the PDF file using the selection tool in TeXShop and then drag-and-drop that section into a document from another application. (Drag and drop to the desktop produces a PDF file called "texshop_image. PDF".)

How do I run a TeX file in TeXShop?

In TeXShop, go to the Typeset menu bar, make sure the LaTeX option is checked, and select Typeset, or simply press Command+T. TeXShop will now try to compile your document. If everything is installed correctly, a compiled PDF document will pop up which says, “Congratulations!

How do I save in TeXShop?

If you copy the source of a file, or drag the entire file to mail, or do similar operations, the file will automatically be saved first and users will always get the latest version. It is still possible to directly save a file using the "Save" menu command or keyboard equivalent.


Video Answer


1 Answers

in case you are still looking for an answer:

  • Go to the Preferences
  • Go to Tab "Engine"
  • Go to Field "pdfTeX"
  • In the LaTeX Input Field add --shell-escape at the end.

before: pdflatex --file-line-error --synctex=1

after: pdflatex --file-line-error --synctex=1 --shell-escape

like image 189
Daniel Avatar answered Oct 07 '22 18:10

Daniel