rcdm-uga / UGA-Dissertation-LaTeX-Template

A dissertation/thesis template in LaTeX approval by the UGA Grad School.
36 stars 16 forks source link

Manuscript-style dissertations #12

Open heathergaya opened 1 year ago

heathergaya commented 1 year ago

This template doesn't allow for manuscript-style dissertations, where each chapter is a different format/style and has its own separate bibliography. I'd like to see UGA come out with a full manuscript-style template, but I wanted to post this workaround in the meantime to help folks like myself who want to use this resource.

The workaround requires a few replacements, but these options could be written in the template (perhaps commented out) to allow students with less LaTeX experience to submit their manuscripts in manuscript style. The necessary changes are:

Remove bibliography from dissertation.tex:

\newpage
\addcontentsline{toc}{chapter}{Bibliography} %add bib to the TOC
\printbibliography[title={Bibliography}]

Replace with each chapter's style and bibliography files:

\renewcommand{\bibname}{References}
\bibliographystyle{Thischapterstyle.sty}
\bibliography{Chapterbibliography.bib}

Compilation is the same as with the current template - however, each chapter's bibtex compilation must be done from the chapter's .tex file instead of from the dissertation.tex file. The compilation steps are:

heathergaya commented 1 year ago

Wanted to note that a bash script can help make edits much easier. Here's one for 4 data chapters, with big intro/conclusion to fit UGA requirements:

#!/bin/bash

# Compile the main dissertation file with pdflatex
pdflatex dissertation.tex 
pdflatex dissertation.tex 

# Run BibTeX on the specified subfiles and redirect errors to a log file
cd ./subfiles
bibtex Chap1_Intro 
cd ./Chap2
bibtex Chap2
cd ../Chap3
bibtex Chap3
cd ../Chap4
bibtex Chap4 
cd ../Chap5
bibtex Chap5
cd ../Chap6_Conclude
bibtex Conclude
cd ../../
# Compile the main dissertation file again to include bibliography changes
pdflatex dissertation.tex 

### Moved to clean.sh
# Clean up temporary files
 rm *.aux *.log *.bbl *.blg *.toc *.out
 cd ./subfiles  
 rm *.aux *.log *.bbl *.blg *.toc *.out

echo "Compilation and BibTeX processing complete. Check error file for problems"