Questions tagged [shell-escape]

{shell-escape} is about the “--shell-escape” argument, i.e. to enable external running of commands from inside the ‘.tex’ file.

Filter by
Sorted by
Tagged with
0
votes
0answers
21 views

Execute/Run Visual Basic Script in relative folder with `\write18` during compilation

To run a visual basic script named readCSV.vbs in/before/during latex compilation, I have the following MWE: \documentclass{article} % line3: %\immediate\write18{readCSV.vbs} %Works If you put it ...
0
votes
1answer
62 views

shell-escape commands fails under W10

I am not a big connoisseur of MS-Windows. To use tikz-plot I need to compile with --shell-escape to run gnuplot. who fails. I tested with latex in interactive mode \ immediate \ write18 {date} which ...
3
votes
2answers
57 views

Expand \def in \write18

I have defined the following command: \newcommand{\formatcommand}[1]{ \def\temp{#1} \def\s{\ifx\temp\empty empty\else not empty\fi} echo "\s" } This works correctly: \formatcommand{} \...
1
vote
1answer
32 views

shellescape macro nested in another macro

How do I use a shellescape (| echo "stuff") macro as another macros input if there are "bad" characters like _ contained. I will use my full example as reference. The idea is to replace \...
0
votes
1answer
41 views

Using listinputlisting to include a specific (git) commit

I am discussing code which is in version control and would like to specify which version of the code to include. I did some research and found packages like gitlatex and gitinfo, but though useful, ...
0
votes
0answers
42 views

How to use escapeinside from minted in an external file

I have managed to do the following \documentclass[12pt]{extbook} \usepackage{geometry} \usepackage[latin1]{inputenc} \usepackage[T1]{fontenc} \usepackage{microtype} \usepackage{xcolor} \usepackage{...
1
vote
1answer
46 views

LuaLaTeX doesn't execute plantuml with Cyrrilic-name file

It's derivative from my previous question: \DeclareGraphicsRule for plantuml doesn't work with LuaLaTeX I have this MWE: \documentclass{article} \usepackage{graphicx} \DeclareGraphicsExtensions{...
0
votes
0answers
31 views

How to take path from batch in LyX2.3.2?

I'm using LyX in Windows 10 and searching to display the path where the file.tex is placed, this file is supposed to be placed in different places and used from different users. I try to explain what ...
7
votes
1answer
110 views

Can I get the output of a command line program with TeX (using e.g. \read18)?

Say I want to call some external program using \write18, which returns some text to the command line. Can I get that text from inside TeX? As an example > inkscape -V returns the version of the ...
0
votes
1answer
88 views

EpsToPdf package does not work

I recently run into a problem where on my laptop i can compile a tex file using eps images but on my pc it does not work instead if i try to compile Libre Office is opening and showing the EPS file. ...
1
vote
1answer
27 views

Escaping the “^” character causes formatting error

Escaping "^" after \tt is causing formatting error in the following code. All words after \^{} is being affected by \tt. Code: \item Use the {\tt linspace} command to create a vector $\mathbf{x} \in ...
0
votes
0answers
17 views

Use output of external command in xifthen

It would like to call the kdb command from Elektra from within LaTeX documents and use its output to write LaTeX conditionals. Ideally, I would like to have something like: \documentclass{article} \...
0
votes
1answer
77 views

How to add compilation parameters -shell-escape with arara

I am having trouble using compiling argument lualatex -shell-escape as mentioned in this question using arara. I cant get the right syntax, and I am failing to find it in arara user manual. I tryed ...
0
votes
1answer
100 views

Blank pdf document

I entered the LaTeX gnuplot code exactly as stated in this site, which should output the sine curve on the output document using TeXworks compiler. It compiles but produces an empty document. An ...
1
vote
1answer
98 views

How to automatically create multiple versions of a document with different paper sizes & reflecting this in the generated PDF filename?

I am using the moderncv class to prepare my resume for applying to jobs in the US (where the standard paper size is letter), and in UK (where the standard paper size is A4). Here is a MWE file called ...
1
vote
0answers
102 views

Texcount command not found system in MacTeX [closed]

I have a problem trying to invoke texcount from LaTeX file. I am using MacOS with MacTeX 2018 installed. texcount comes directly with the MacTeX and it is on the PATH. When I run texcount on command ...
2
votes
1answer
61 views

Conditional output dependent on --shell-escape option value

I would like to print the git revision of the document with the latexgit package, which requires the --shell-escape option to work. As this feature is very optional for building the document, I would ...
5
votes
1answer
197 views

mail merge and create multiple pdfs

I have a .csv file called sbriefdata with some data in it, for example A;B;10 C;D;20 E;F;30 G;H;40 and I want a separate .pdf file for each of the rows in the .csv file. I know how to do a mail ...
1
vote
1answer
136 views

pdfLaTeX not accepting shell commands despite shell-escape option

I am testing the shell escape option, but I am stuck on a very early level -trying to do: \input{|"time /t"}}. My pdfLaTeX is complaining: ! LaTeX Error: File `|"time /t".tex' not found. As far as I ...
0
votes
1answer
132 views

How to make LuaLaTeX multithreaded when `--shell-escape` is enabled? [duplicate]

I found this thread: How to make pdfLaTeX multithreaded when `--shell-escape` is enabled? It works great. But when I change to LuaLaTeX there is still just 1 cpu active. So is there a way to achive ...
2
votes
1answer
114 views

how to compile tex file with -shell-escape in AucTeX using C-c C-c on ubuntu

I want to compile my tex file with -shell-escape option in Emacs + AucTex using C-c C-c key binding. It gave me an error to run with -shell-escape. I know I can do it through terminal by latex -shell-...
0
votes
0answers
66 views

Making \psfrag replacement without using --shell-escape option

I am trying to submit latex manuscript on ScholarOne. In the latex file, I have used \psfrag to make text replacement on .eps file. On my PC I can use auto-pst-pdf package and compile the .tex file ...
2
votes
1answer
239 views

shell-escape and “tput: No value for $TERM and no -T specified”

I am using TexStudio 2.12.6 on TexLive 2015 (Debian). If I add the option --shell-escape to my compile command lualatex --shell-escape -synctex=1 -interaction=nonstopmode -halt-on-error %.tex, I ...
1
vote
0answers
89 views

Can't execute jar from directory with umlaut

Okay so this is quite an exotic question and I am unsure whether it really fits on this page. But as it involves LaTeX I'll post it here. I have written a Java program that I am calling from inside ...
0
votes
0answers
709 views

Enable pdflatex -shell-escape in TeXstudio [duplicate]

My latex editor is TeXstudio and I need to configure it to enable pdflatex -shell-escape, is it possible to do it? compile with pdfLaTex, use Windows 10 and MikteX 2.9
0
votes
0answers
117 views

Display error messages in TeXstudio (--shell-escape)

In order to get three output files at the same time (by one compilation) I added the option --shell-escape and \ifx\conditionmacro\undefined \immediate\write18{% pdflatex --jobname="\jobname" ...
0
votes
3answers
115 views

How to use “Kpathsea” to open a sty file for users modifications

I have a package to create exam paper sujet.sty, in this package I have defined some commands like school which expand to the name of school. \def\school{name-of-school} I thought about using a ...
3
votes
0answers
100 views

A simple example on how to use shell-escape option

I have got an issue when using the moodle package which I suspect is related to the -shell-escape option see this question on TeX-exchange: error when using tikzpicture with moodle package. In my ...
3
votes
2answers
234 views

error when using tikzpicture with moodle package

I want to generate a quiz for my students to be imported within the moodle platform . The quiz includes some figure. I tried the moodle package from texlive 2018 but I get the following error when ...
2
votes
1answer
200 views

Tikz external with beamer animations

I'm trying to speed-up compilation of my multi-tikz .tex file. I found this topic and successfully applied the solution ; unfortunately, it doesn't work for animations inside the tikzfigure: Only the ...
0
votes
0answers
30 views

Can I make TeX echo what the document sends to \write18?

I'd like to see what's being sent to the shell (if it is indeed a real shell and not some direct process-spawning) during compilation of my document. (I've solved my original problem, but this ...
2
votes
0answers
139 views

Shell command error when compiling with LuaLaTeX shell-escape in Fedora 28 [closed]

When compiling this minimal TeX file with lualatex --shell-escape test.tex I get an initial shell error (that is output to stderr), sh: all: command not found (check in the 7th line). The error doesn'...
3
votes
1answer
154 views

Does --no-shell-escape break \pdf@shellescape?

Edit: since posting the question I've fixed a few mistakes. I don't think they affect the answer given below, but I wanted to correct the record for completeness. Background I have a Python script ...
1
vote
0answers
202 views

Externalize Tikz picture result in error 'pdflatex -holt-on-error but shell escape is used

I am trying to externalize tikz-picture by using the externalize library. I am using Miktex 2.9. I activate the external feature by using \tikzexternalize and also tried \tikzexternalize[shell ...
0
votes
0answers
30 views

Upcase script in titleformat causes TeX capacity exceeded error

I'm trying to get \titleformat to use a shell script upcase instead of \MakeUppercase to upcase the section title in the document but not in the table of contents. (I know \MakeUppercase achieves ...
1
vote
1answer
137 views

dot2texi fails to convert automatically due to “Shell escape not enabled.” not matter whether -shell-escape is specified to lualatex

The following document fails to compile properly/automatically because dot2texi fails to convert the dot specification and warns about it with Package dot2texi Warning: Shell escape not enabled. (...
1
vote
1answer
46 views

Seamless invocation of bib de-duplication script from document source preamble?

Unfortunately, for reasons beyond my control, I am stuck with mendeley as my citation manager which provides an option to export its library to a bib file. My mendeley library is organised into ...
4
votes
1answer
488 views

Is it possible to use the graphviz package on ShareLaTeX?

I am trying to use the graphviz package on ShareLaTeX. I have included both the graphviz and graphicx packages \usepackage[pdf]{graphicx} \usepackage{graphviz} I tried running the simple example ...
5
votes
1answer
174 views

Using standalone package to reduce tikz compile time

I am using standalone package by Martin Scharrer in a report. I read in this answer by Martin that if the document loads with a [mode=buildnew]{standalone} package, then for each picture that is ...
2
votes
1answer
304 views

How to escape to latex within minted comments?

I am using the minted package for typesetting matlab source code. There is an escapeinside option for the listing environment provided by minted to escape to regular TeX commands. However, this does ...
1
vote
1answer
54 views

use shell-escape output with newlines in pgfplots/tikz

The following example works: \documentclass{article} \usepackage{pgfplots} \begin{document} \begin{tikzpicture} \begin{axis} \addplot table{ 0 0 0.5 0.25 1 1 }; \end{axis} \end{tikzpicture} \end{...
3
votes
1answer
838 views

How to enable shell escape when building with latexmk and xelatex

The title already says the question. I want to clarify that this is not a duplicate, because existing answers are all for plain latex or pdflatex. Building with latexmk and pdflatex with shell ...
2
votes
1answer
143 views

Input from external program to tikz as a LaTeX command with several arguments

I am in need of a command \myprogram that takes 3 optional and 1 mandatory arguments. When using pdfLateX --shell-escape, \myprogram should call echo '(#1,#2) parabola (#3,#4)' (echo stands here ...
1
vote
1answer
73 views

Combine path from external program with \draw in tikz

I have an external program bezierplot which returns tikz paths. E. g. bezierplot 'x^2' returns (-2.24,5) parabola bend (0,0) (2.24,5); with semicolon. Now I want to call the program with shell-escape/...
1
vote
1answer
239 views

Execute external bash file

This is a follow up to Get write18 to execute after file parsing With the code \documentclass[a4paper,10pt]{article} \usepackage[utf8]{inputenc} \usepackage{graphicx,grffile} \newcommand{\filename}...
1
vote
1answer
67 views

Get write18 to execute after file parsing

Follow up to Get write18 to accept / expand command I want to crop a pdf and print it. My \the\pdfshellescape is 1, so my shell-escape is working. My MWE is \documentclass[a4paper,10pt]{article} \...
4
votes
1answer
180 views

Get write18 to accept / expand command

I am trying to use write18 to crop a pdf. The code is \documentclass[a4paper,10pt]{article} \usepackage[utf8]{inputenc} \usepackage{graphicx} \newcommand{\filename}{} \newcommand{\croppedfilename}{}...
2
votes
1answer
108 views

Dependence of \write18 to svg-package

In the following MWE I am experiencing a (to me) very weird dependence of the \write18 command and the svg package. \documentclass{article} \RequirePackage{svg} \begin{document} \immediate\...
0
votes
0answers
1k views

Minted: -shell-escape flag [duplicate]

I'm trying to get some source code into my tex-document but only get the error message mentioned in the thread title. I disabled nearly all of the other packages I use but it did not work. \...
1
vote
1answer
226 views

Converting pgfplots usage to includegraphics (cannot use -shell-escape)

I am uploading a paper to arxiv, which does not allow the use of shell-escape. Currently my paper uses pgfplots as in the following MWE: temp.tex ---------------------------- \documentclass{article} ...