I am struggling to compile a file locally either in TexMaker or Atom that nevertheless compiles fine on ShareLatex.com (where I originally made it).
My file is of the form...
\documentclass{article}
%\documentclass[draft]{article}
\usepackage[utf8]{inputenc}
\usepackage[style=authoryear, uniquename=false, sorting=nyvt, backend=biber, doi=false, isbn=false, maxcitenames=2]{biblatex}
\usepackage{graphicx}
\usepackage{rotating}
\newcommand*{\bibtitle}{References}
\renewcommand*{\bibfont}{\raggedright\small}
\usepackage[english]{babel}
\usepackage[autostyle, english = american]{csquotes}
\MakeOuterQuote{"}
\addbibresource{references.bib}
\usepackage[singlelinecheck=false]{caption}
\usepackage{glossaries}
\makeglossaries
\input{glossary}
\title{TITLE OF DOC}}
\author{MY NAME}
\date{DATE RIGHT NOW}
\begin{document}
\maketitle
\textbf{Abstract:} Some stuff about the doc.
\clearpage
\tableofcontents
\clearpage
\include{sections/outline}
\include{sections/introduction}
\include{sections/extended_info}
\include{sections/first_bits}
\input{sections/not_done_yet}
\input{sections/also_not_done_yet}
\input{sections/this_will_be_the_conclusion}
\clearpage
\printglossary[style=long]
\clearpage
\setlength{\baselineskip}{0pt} % JEM: Single-space References
{\renewcommand*\MakeUppercase[1]{#1}%
\printbibliography[heading=bibintoc,title={\bibtitle}]}
\end{document}
So, basically, it all compiles beautifully on SharLatex.com, but on my local machine (with both TexMaker and Atom plugin) it fails because:
I can't write on file 'sections/outline.aux'
That gives a fatal error.
Now, I know that maybe I should be using \input
instead of \include
(although I don't know why!), and you're probably wondering why some document sections use one and not the other... but that's because of how it results in \clearpages
after \include
but not \input
(I wanted those last input sections all on one page, because they are currently just empty titles).
Now, I would change it all to \input
(and indeed the document then compiles), but that results in my images all going to the end of the document after all sections, and having no clear pages, and that's all a mess I don't want!
So is there any way I can keep my \include
and \input
commands exactly as they are currently (indeed, keep it all as it is) but add something to make it compile properly? Or am I doing something terribly terribly wrong that I don't understand?
Any help appreciated (relatively new to LaTeX)...
EDIT
Tried chmodding the directory and contents both to 666 and 777 and neither works, same error occurs:
This is the error in the log:
./main.tex:61: I can't write on file `sections/outline.aux'.
\@include ...\immediate \openout \@partaux #1.aux
\immediate \write \@partau...
l.61 \include{sections/outline}
(Press Enter to retry, or Control-D to exit; default file extension is `.tex')
Please type another output file name
./main.tex:61: Emergency stop.
\@include ...\immediate \openout \@partaux #1.aux
\immediate \write \@partau...
l.61 \include{sections/outline}
*** (job aborted, file error in nonstop mode)
EDIT 2
I realise this is a bit of a dead end, but even if I chmod -R 777 the entire project folder it won't play ball... but if I put the files in the main directory (and change the code path) it's fine and compiles, so definitely permissions... am going crazy trying to understand what the problem is. Using Linux Mint.
EDIT 3
If I switch to using the Javascript DiCy builder in Atom's latex package then it compiles fine (as opposed to using latexmk)... therefore, I think this could be something to do with latexmk's config... is it possible there is an issue similar to MiKTeX has with openout_any=a ? If so, is there a setting that can be changed in latexmk to stop this from happening and allow everything to compile fine?
maindir
is the directory where your main.tex
file is, do you have the included files inmaindir/sections
, and is that directory writeable by TeX?I can't write on file 'sections/outline.aux'
does that directory and file exist, and what file permissions do they have?