sphinx-doc / sphinx-doc/sphinx
Customization of the bibliography in LaTeX output
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 8k
- Forks
- 2.6k
- PR merge metrics
- No merged PRs in 30d
Description
This is a feature request that was discussed in the mailing list:
https://groups.google.com/forum/#!topic/sphinx-dev/qHIpc7XskZY
Problem
When using the sphinxcontrib-bibtex extension, the list of references can be placed in the document with the bibliography directive. At least that's the case for HTML output; in LaTeX output, the list of references is moved to the very end of the resulting LaTeX document.
This is documented: https://sphinxcontrib-bibtex.readthedocs.io/en/latest/usage.html#mismatch-between-output-of-html-and-latex-backends
The reason for this behavior is sphinx.builders.latex.BibliographyTransform, which cannot easily be disabled.
A work-around is shown there: https://github.com/mcmtroffaes/sphinxcontrib-bibtex/issues/156
In the mailing list, @tk0miya said:
I can provide the option for the transform like "as is", "per
chapter" and "per document".
If you like it, please post a feature request. I'll work for it (in future).
I think such an option would be great.
I'm mostly interested in the "as is" option, but other people might also want "per chapter".
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading sphinx.builders.latex.BibliographyTransform and the documented HTML/LaTeX mismatch. Review the linked sphinxcontrib-bibtex workaround and mailing-list discussion for the intended “as is” and “per chapter” behaviors. Done means LaTeX bibliography placement can be selected without disabling the transform manually.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- latex, python
- Domain
- documentation
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100