ethz-thesis
ethz-thesis copied to clipboard
Bibliography & citations fail - March 2020
Hi,
First of all thank you for the great template! When I run your original thesis.tex file with TeXShop (4.44), everything works except the bibliography. Citations are not shown correctly, e.g. [codata] instead [1] and the bibliography is not printed at all.
Do you have any solution to this problem?
Cheers
Just tested with MacTeX 2019 and the TeXShop 4.44. The problem is with the commands for compiling the TeX files and bibliography, which default to pdflatex and bibtex.
Change it to pdflatexmk and everything works as expected:

See also more details in https://github.com/tuxu/ethz-thesis/issues/3, which describes essentially the same problem.
Hello,
Thank you for your help, with pdflatexmk it works for me as well!
Another question: for my thesis I would like to have separated references for every chapter. How would you implement that?
I already tried the following within the main.tex file of individual chapters:
\begin{refsection}[bibliography]
\printbibliography[heading=none]
\end{refsection}[bibliography]
Unfortunately this was not successful. Somehow it creates a bibliography of all references from the whole document (after the first chapter) and the subsequent bibliographies+citations do not work..
I would appreciate any hint!
Cheers
One solution is to copy compile the chapters separately, and copy paste the .bbl file content into the chapter. A bit hacky but does the trick
Seems like the most elegant way is with biblatex' refsection environment. Did you try without the [bibliography]?
There's a complete example on Overleaf: https://de.overleaf.com/latex/examples/per-chapter-bibliographies-with-biblatex/yhdqvxtftwxf
Thank you very much @tuxu for this amazing template.
One glitch I spent quite some time fixing is the biblatex to natbib, when using authoryear style, which is the required style of ETHZ dissertation nowadays.
The former will be outdated quite soon, so the standard bibliography package is natbib.
One needs to only change the following lines.
- In
preamble/general.txt,
% % Biblatex % \input{preamble/biblatex} % do not use this \usepackage[sort]{natbib} \setcitestyle{authoryear} \bibliographystyle{plainnat}
- In
thesis.tex,
% \cleardoublepage\include{frontbackmatter/bibliography}
\bibliographystyle{plainnat} % Specify the bibliography style \bibliography{bibliography} % Specify the name of your .bib file