2

I often have to create documents with multiple sections, and each section might have contain references, which of course are global to the document.

I want to be able to compile one section of the document at a time, and be able to automatically cross-reference my citations.

However, as far as I can tell, there is no way to do that without also including the Bibliography section. Is there a way to compile a single section of a document such that all of the citations get properly referenced, but the works cited page does not?

For instance, my MainDocument.tex file might read:

\begin{document}
...
\include{section1}
%\include{section2}
...
\include{references}
...
\end{document}

If I comment out the references section, then all my citations obviously show up as [?].

Any way to do what I'm looking to do?

1 Answer 1

3

You can use \includeonly. First you process your document with the \includeonly line commented out as many times as necessary to get cross-references, citations, and all elements right; next you uncomment the \includeonly line and process the document again.

An example: first you will process this document until it's stable:

\documentclass{article}

%\includeonly{section1}

\begin{document}

\include{section1}
\include{section2}
\include{references}

\end{document}

and then you work only on section1 with this:

\documentclass{article}

\includeonly{section1}

\begin{document}

\include{section1}
\include{section2}
\include{references}

\end{document}
0

You must log in to answer this question.

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