sisl/tufte_algorithms_book

Compiling only chapters

BeastyBlacksmith opened this issue · 4 comments

you mentioned in the juliacon-talk that it is possible to compile chapters separately. How is this done?

Good question. You can simply comment out the sections in book.tex you don't want to compile.

IE something like:

\begin{document}
% \frontmatter
% \input{titlepage}
% \include{copyrightpage}
% \include{dedication}
% \forceheader{Contents}
% \tableofcontents
% \include{chapter/preface}
% \include{chapter/acknowledgments}

\mainmatter
\begin{jlcode}
	include("../support_code.jl")
\end{jlcode}
\include{chapter/introduction}

% Add additional include statements for your other chapters.
% \appendix
% \include{chapter/appendix}
% \solutions
% \backmatter
% \chapter*{References}
% \addcontentsline{toc}{chapter}{References}
% \forceheader{References}
% \printbibliography[heading=none]

% \forceheader{Index}
% \printindex

\end{document}

In Alg4Opt we had a separate .tex file for compiling standalone chapters, but we still used this simple comment-out technique.

What about pull_section.jl? I thought that's written for this purpose but I didn't had a chance to dig into it.

Oh, I forgot that I pushed that. I wrote that but never ended up using it. I find it much easier to just consistently compile the book and comment / uncomment.

Closed by #14