I am quite new to LateX and I have been trying for the past few days to do a Shell escape in Miktex 2.9/ TeXworks in my pdflatex+Makeindex+bibtex typesetter so that I could be able to use the CSVsorter presented in the CSVsimple package.
I tried the methods presented Here, and Here.
When I try to compile my tex
\csvreader[sort by=table/namesort.xml,
head to column names,
tabular=>{\color{red}}lllll,
table head=\toprule year of birth\\\midrule,
table foot=\bottomrule]
{./table/csvsimple-example.csv}{}{\csvlinetotablerow}
I obtain this error :
sort "./table/csvsimple-example.csv" by "./table/namesort.xml">
("C:…\My tex.csvtoken"
! Package csvsimple Error: Call of CSV-Sorter failed! Use '-shell-escape' optio
n or check log file 'csvsorter.log'..See the csvsimple package documentation for explanation.
Type H for immediate help.
…l.1 …ption or check log file 'csvsorter.log'.}{}
But I have no log file to start with. So I don't know if it is a programming error or a problem to configure -shell-escape
Thank you
Best Answer
Since the command line version works for the OP, it looks like a TeXWorks setup problem.
The following additions to the TeXWorks compilation options work for me. I am sorry for german texts in the screenshots from my PC.
The first one is for setting up a pdfLaTeX compile option with
--shell-escape
:The second one is for a pdfLaTeX+MakeIndex+BibTeX compile option with
--shell-escape
:With both settings the example from http://t-f-s.github.io/csvsorter/ compile.
Prerequisite is that the
CSVsorter
program is found on the system path. Putting it into the source directory of the LaTeX example also works.The files for the example are the following:
songcontest.tex:
songcontest.csv:
sumsort.xml:
My example directory contains the following files: