https://github.com/compwa/sphinx-pybtex-etal-style
Abbreviate long author lists with et al. in BibTeX bibliographies for Sphinx
https://github.com/compwa/sphinx-pybtex-etal-style
Last synced: 3 months ago
JSON representation
Abbreviate long author lists with et al. in BibTeX bibliographies for Sphinx
- Host: GitHub
- URL: https://github.com/compwa/sphinx-pybtex-etal-style
- Owner: ComPWA
- License: bsd-3-clause
- Created: 2023-12-04T11:58:20.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2026-02-04T16:14:19.000Z (4 months ago)
- Last Synced: 2026-02-05T03:48:59.324Z (4 months ago)
- Language: Python
- Homepage:
- Size: 61.5 KB
- Stars: 0
- Watchers: 5
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
Awesome Lists containing this project
README
# `sphinx-pybtex-etal-style`
[](https://pypi.org/project/sphinx-pybtex-etal-style)
[](https://pypi.org/project/sphinx-pybtex-etal-style)
[](https://opensource.org/licenses/BSD-3-Clause)
[](https://open.vscode.dev/ComPWA/sphinx-pybtex-etal-style)
[](https://github.com/ComPWA/sphinx-pybtex-etal-style/actions?query=branch%3Amain+workflow%3ACI)
[](https://results.pre-commit.ci/latest/github/ComPWA/sphinx-pybtex-etal-style/main)
[](https://github.com/streetsidesoftware/cspell/tree/main/packages/cspell)
[](https://github.com/prettier/prettier)
[](https://github.com/astral-sh/ruff)
[](https://github.com/astral-sh/uv)
[](https://github.com/astral-sh/ty)
This Sphinx extension defines a new bibliography style for the [`sphinxcontrib-bibtex`](https://sphinxcontrib-bibtex.rtfd.io) extension. Install through [PyPI](https://pypi.org) with `pip`:
```bash
pip install sphinx-pybtex-etal-style
```
Next, in your [Sphinx configuration file](https://www.sphinx-doc.org/en/master/usage/configuration.html) (`conf.py`), add `"sphinx_pybtex_etal_style"` to your `extensions`:
```python
extensions = [
"sphinx_pybtex_etal_style",
]
```
and set your [default bibliography style](https://sphinxcontrib-bibtex.readthedocs.io/en/stable/usage.html#bibliography-style) to `"unsrt_et_al"`:
```python
bibtex_default_style = "unsrt_et_al"
```
Alternatively, you can use the style for one bibliography only by specifying it in the [`.. bibliography::` directive](https://sphinxcontrib-bibtex.readthedocs.io/en/stable/usage.html#directive-bibliography):
```rst
.. bibliography:: /references.bib
:style: unsrt_et_al
```
Book entries that have an ISBN get a link to the book entry on [bookfinder.com](https://bookfinder.com/search). If you want to use [isbnsearch.org](https://isbnsearch.org) instead, add the following to your `conf.py`:
```python
unsrt_etal_isbn_resolver = "isbnsearch"
```
To activate LaTeX math support in bibliographies (e.g. via MathJax), add the following to your `conf.py`:
```python
bibtex_use_mathjax = True
```