I am working on a project and i want to slim it down a litle so please help me with the following. I have a document structure like this:
/DocumentRoot
|-main.tex
|-title.tex
|
|-/chapter-1
| |-/images
| |-chapter-1.tex
|
|-/chapter-2
|-/images
|-chapter-2.tex
My document is like this:
\begin{document}
\include{./title}
\include{./chapter-1/chapter-1}
\include{./chapter-2/chapter-2}
\include{./chapter-3/chapter-3}
\end{document}
in my chapters i use both some images and some heavy tikz plots so i use externalize and draft options for quicker compilation. But i want the images to be placed in the respective chapter folders but for example in chapter 3 this works:
\includegraphics[width=\linewidth]{./chapter-3/images/img.jpg}
and this doesn't
\includegraphics[width=\linewidth]{./images/img.jpg}
for some reason xelatex has problems with the relative paths of included chapters. I also want to control the location output and the naming of the externalized tikz documents. Any help with that? I am working with miktex and texworks.