alexpovel / latex-cookbook

A comprehensive LaTeX template with examples for theses, books and more, employing the 'latest and greatest' (UTF8, glossaries, fonts, ...). The PDF artifact is built using CI/CD, with a Python testing framework.
MIT License
217 stars 20 forks source link

glossaries-extra fails to recognize which entries have actually been used #6

Closed alexpovel closed 2 years ago

alexpovel commented 2 years ago

Original issue (2021-10-18): https://collaborating.tuhh.de/alex/latex-cookbook/-/issues/13

It seems glossaries-extra no longer recognizes which references have occurred (using \gls{} etc.).

alexpovel commented 2 years ago

This used to be in conjunction with the subimport package. We currently (cd77fddd032842885ca5d99cd96ba32f0f941c97) use import instead:

https://github.com/alexpovel/latex-cookbook/blob/b847c85b0d4835a98889c0d2f948e32278b637fb/.devcontainer/image/acp.cls#L78

The subimport package introduces a neat structure to have subdirectories and do nested imports of *.tex files. But that might not be worth it, since it breaks many referencing functionalities in for example TeXStudio.

Also, to circumvent this subimport downside, we used to and currently (cd77fddd032842885ca5d99cd96ba32f0f941c97) still call:

https://github.com/alexpovel/latex-cookbook/blob/b847c85b0d4835a98889c0d2f948e32278b637fb/.devcontainer/image/acp.cls#L2788

to load all stuff found in the respective *.bib file, regardless of whether it has actually been called at some point. This is a bit like if biblatex did not recognize cite commands and we just pulled every single item in the bibliography file. Some people use gigantic *.bib files, shared among their projects. If suddenly every entry showed up in the printed document despite not being referenced (be it a glossary or a bibliography item), chaos would ensue.