1

I have a .tex file which tries to input another local file:

%!TEX root = ../rings.tex
\pagebreak
\chapter{Analisis}
\input{toLatex}

Both files analisis.tex and toLatex.tex reside in the same folder:

$latex/01_analisis$ ll
total 24
drwxrwxr-x 2 lucas lucas 4096 abr 13 12:30 ./
drwxrwxr-x 4 lucas lucas 4096 abr 13 12:41 ../
-rw-rw-r-- 1 lucas lucas  130 abr 13 12:41 analisis.tex
-rw-rw-r-- 1 lucas lucas 9919 abr 13 12:37 toLatex.tex

However, when I try to get the pdf (I'm using Sublime-text) I get an error message saying toLatex cannot be found.

[Compiling latex/rings.tex]

TraditionalBuilder: Engine: pdflatex. Invoking latexmk... done.

Errors:

latex/01_analisis/analisis.tex:11: LaTeX Error: File `toLatex.tex' not found. [\input{toLatex}]

It's weird because in the main.tex file I'm already using the \input{} command and it's working.

\begin{document}

\maketitle
\def\contentsname{Indice}
\tableofcontents{}
\def\listfigurename{Figuras}
\listoffigures
\def\listtablename{Tablas} 
\listoftables

\input{00_intro/intro}
\input{01_analisis/analisis}

\pagebreak

\end{document}

Any hint? thanks!

2
  • 1
    looking at your sketch I assume you need \input{01_analisis/toLatex} the paths are relative to the working directory of the tex process Commented Apr 13, 2020 at 15:59
  • thanks ... this solved it ... Commented Apr 13, 2020 at 16:06

1 Answer 1

2

You need

 \input{01_analisis/toLatex} 

the paths are relative to the working directory of the tex process, not to the file in which the \inout command appears.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .