TransWikia.com

inputminted can't find the source code file

TeX - LaTeX Asked by Shanksum on July 16, 2021

I’m trying to import a Python script into my LaTeX document using inputminted, but it only works if I use the absolute path.
E.g. this works:
inputminted{python}{C:/Documents/example.py}
This does not, although the .tex and the .py file are in the same folder:
inputminted{python}{example.py}

The error is:

! Package minted Error: Missing Pygments output; inputminted was  
probably given a file that does not exist--otherwise, you may need  
the outputdir package option, or may be using an incompatible build tool,  
or may be using frozencache with a missing file.

I’m using TeXworks with the default pdfLaTeX+MakeIndex+BibTex builder, but added --tex-option=--shell-escape for minted to work.

Any ideas why I cannot use this relative path?

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP