Name | betterbib JSON |
Version |
7.3.1
JSON |
| download |
home_page | None |
Summary | Better bibliography data |
upload_time | 2025-01-02 18:12:47 |
maintainer | None |
docs_url | None |
author | None |
requires_python | >=3.9 |
license | None |
keywords |
bibtex
latex
|
VCS |
|
bugtrack_url |
|
requirements |
No requirements were recorded.
|
Travis-CI |
No Travis.
|
coveralls test coverage |
No coveralls.
|
<p align="center">
<img alt="betterbib" src="https://raw.githubusercontent.com/texworld/betterbib/assets/betterbib.svg" width="60%">
</p>
[![PyPi Version](https://img.shields.io/pypi/v/betterbib.svg?style=flat-square)](https://pypi.org/project/betterbib)
[![PyPI pyversions](https://img.shields.io/pypi/pyversions/betterbib.svg?style=flat-square)](https://pypi.org/pypi/betterbib/)
[![GitHub stars](https://img.shields.io/github/stars/texworld/betterbib.svg?style=flat-square&logo=github&label=Stars&logoColor=white)](https://github.com/texworld/betterbib)
<!-- [![Downloads](https://pepy.tech/badge/betterbib/month?style=flat-square)](https://pepy.tech/project/betterbib) -->
<!--[![PyPi downloads](https://img.shields.io/pypi/dm/betterbib.svg?style=flat-square)](https://pypistats.org/packages/betterbib)-->
[![Discord](https://img.shields.io/static/v1?logo=discord&logoColor=white&label=chat&message=on%20discord&color=7289da&style=flat-square)](https://discord.gg/hnTJ5MRX2Y)
Bibliography files are notoriously hard to work with. Betterbib contains
a number of easy-to-use command-line tools to help.
- [`betterbib convert`](#convert) converts between different bibliography formats, e.g.
- [BibTeX](https://www.bibtex.org/Format/)
- [BibLaTeX](https://ctan.org/pkg/biblatex)
- [RIS](<https://en.wikipedia.org/wiki/RIS_(file_format)>)
- [CSL-JSON](https://citeproc-js.readthedocs.io/en/latest/csl-json/markup.html)
- [`betterbib sync`](#sync) syncs bibliography data with a number of online sources, e.g.,
- [Crossref](https://www.crossref.org/)
- [DBLP](https://dblp.uni-trier.de/)
- [PubMed](https://pubmed.ncbi.nlm.nih.gov/)
- [arXiv](https://arxiv.org/)
- [Zenodo](https://zenodo.org/)
- [`betterbib format`](#format) formats your bibliography files to your liking.
Can also (un)abbreviate author and journal names.
- [`betterbib doi-to`](#dereference-dois) converts a DOI or DOI URL to a bibliography entry.
### Installation
Install betterbib [from PyPI](https://pypi.org/project/betterbib/) with
<!--pytest.mark.skip-->
```
pip install betterbib
```
See [here](https://github.com/texworld) for licensing information.
#### Convert
#### Sync
Simply run
<!--pytest.mark.skip-->
```sh
betterbib sync in.bib
```
to sync your bibliography file with online sources. For example, the input
```bibtex
@article{wiles,
title={Fermat Last Theorem},
doi={10.2307/2118559},
}
```
is converted to
```bibtex
@article{wiles,
number = {3},
doi = {10.2307/2118559},
pages = {443},
source = {Crossref},
volume = {141},
author = {Wiles, Andrew},
year = {1995},
month = may,
url = {https://doi.org/10.2307/2118559},
issn = {0003-486X},
journal = {The Annals of Mathematics},
publisher = {JSTOR},
title = {Modular Elliptic Curves and Fermat's Last Theorem},
}
```
See `-h`/`--help` for all options.
<!--pytest.mark.skipif(sys.version_info < (3, 11), reason="Need Python 3.11+")-->
```sh
betterbib sync -h
```
<!--pytest-codeblocks: expected-output-ignore-whitespace-->
```
Usage: betterbib sync [-h] [-i] [-c N] [-s SRC] [-m MINIMUM_SCORE] [-q] [--debug]
[--output-format {bibtex,biblatex,csl-json,ris}]
infiles [infiles ...]
Positional Arguments:
infiles input bibliography files
Options:
-h, --help show this help message and exit
-i, --in-place modify infile in place
-c, --num-concurrent-requests N
number of concurrent HTTPS requests (default: 1)
-s, --sources SRC sources to try (comma-separated, with order; default:
crossref,dblp,pubmed)
-m, --minimum-score MINIMUM_SCORE
minimum score to count as a match (default: 0.0)
-q, --quiet don't show progress info (default: show)
--debug some debug output (default: false)
--output-format {bibtex,biblatex,csl-json,ris}
force output format (default: same as input)
```
#### Format
After that, you can for example run
```
betterbib format in.bib --sort-fields --align-values --journal-names short --abbrev-first-names
```
to get
```bibtex
@article{wiles,
author = {Wiles, A.},
doi = {10.2307/2118559},
issn = {0003-486X},
journal = {Ann. Math.},
month = may,
number = {3},
pages = {443},
publisher = {JSTOR},
source = {Crossref},
title = {Modular Elliptic Curves and Fermat's Last Theorem},
url = {https://doi.org/10.2307/2118559},
volume = {141},
year = {1995},
}
```
```sh
betterbib format -h
```
<!--pytest.mark.skipif(sys.version_info < (3, 11), reason="Need Python 3.11+")-->
```
Usage: betterbib format [-h] [-i] [--drop DROP] [--journal-names {long,short,unchanged}] [--abbrev-first-names]
[--sort-entries] [--sort-fields] [--doi-url-type {unchanged,old,new,short}]
[--page-range-separator PAGE_RANGE_SEPARATOR] [--protect-title-capitalization]
[--indent [INDENT]] [--align-values]
infiles [infiles ...]
Positional Arguments:
infiles input BibTeX files
Options:
-h, --help show this help message and exit
-i, --in-place modify infile in place
--drop DROP drop fields from entries (can be passed multiple times)
--journal-names {long,short,unchanged}
force full or abbreviated journal names (default: unchanged)
--abbrev-first-names abbreviate first names in author lists etc. (default: false)
--sort-entries sort entries alphabetically by BibTeX key (default: false)
--sort-fields sort fields alphabetically (default: false)
--doi-url-type {unchanged,old,new,short}
DOI URL (new: https://doi.org/<DOI>, short: https://doi.org/abcde) (default: new)
--page-range-separator PAGE_RANGE_SEPARATOR
page range separator (int or string, default: unchanged)
--protect-title-capitalization
brace-protect names in titles (e.g., {Newton}; default: false)
--indent [INDENT] indentation (int or string; default: 1)
--align-values align field values (default: false)
```
#### Dereference DOIs
Given a DOI or a DOI URL, it's often useful to generate a bibliography entry for it. `betterbib doi-to` does just that.
```sh
betterbib doi-to ris 10.1002/andp.19053221004
```
<!--pytest-codeblocks: expected-output-ignore-whitespace-->
```ris
TY - JOUR
IS - 10
DO - 10.1002/andp.19053221004
SP - 891
EP - 921
DS - Crossref
VL - 322
AU - Einstein, A.
DA - 1905/01
UR - https://doi.org/10.1002/andp.19053221004
SN - 0003-3804
SN - 1521-3889
JF - Annalen der Physik
JO - Ann. Phys.
PB - Wiley
TI - Zur Elektrodynamik bewegter Körper
ER -
```
Raw data
{
"_id": null,
"home_page": null,
"name": "betterbib",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.9",
"maintainer_email": null,
"keywords": "bibtex, latex",
"author": null,
"author_email": "Nico Schl\u00f6mer <nico.schloemer@gmail.com>",
"download_url": null,
"platform": null,
"description": "<p align=\"center\">\n <img alt=\"betterbib\" src=\"https://raw.githubusercontent.com/texworld/betterbib/assets/betterbib.svg\" width=\"60%\">\n</p>\n\n[![PyPi Version](https://img.shields.io/pypi/v/betterbib.svg?style=flat-square)](https://pypi.org/project/betterbib)\n[![PyPI pyversions](https://img.shields.io/pypi/pyversions/betterbib.svg?style=flat-square)](https://pypi.org/pypi/betterbib/)\n[![GitHub stars](https://img.shields.io/github/stars/texworld/betterbib.svg?style=flat-square&logo=github&label=Stars&logoColor=white)](https://github.com/texworld/betterbib)\n\n<!-- [![Downloads](https://pepy.tech/badge/betterbib/month?style=flat-square)](https://pepy.tech/project/betterbib) -->\n<!--[![PyPi downloads](https://img.shields.io/pypi/dm/betterbib.svg?style=flat-square)](https://pypistats.org/packages/betterbib)-->\n\n[![Discord](https://img.shields.io/static/v1?logo=discord&logoColor=white&label=chat&message=on%20discord&color=7289da&style=flat-square)](https://discord.gg/hnTJ5MRX2Y)\n\nBibliography files are notoriously hard to work with. Betterbib contains\na number of easy-to-use command-line tools to help.\n\n- [`betterbib convert`](#convert) converts between different bibliography formats, e.g.\n\n - [BibTeX](https://www.bibtex.org/Format/)\n - [BibLaTeX](https://ctan.org/pkg/biblatex)\n - [RIS](<https://en.wikipedia.org/wiki/RIS_(file_format)>)\n - [CSL-JSON](https://citeproc-js.readthedocs.io/en/latest/csl-json/markup.html)\n\n- [`betterbib sync`](#sync) syncs bibliography data with a number of online sources, e.g.,\n\n - [Crossref](https://www.crossref.org/)\n - [DBLP](https://dblp.uni-trier.de/)\n - [PubMed](https://pubmed.ncbi.nlm.nih.gov/)\n - [arXiv](https://arxiv.org/)\n - [Zenodo](https://zenodo.org/)\n\n- [`betterbib format`](#format) formats your bibliography files to your liking.\n Can also (un)abbreviate author and journal names.\n\n- [`betterbib doi-to`](#dereference-dois) converts a DOI or DOI URL to a bibliography entry.\n\n### Installation\n\nInstall betterbib [from PyPI](https://pypi.org/project/betterbib/) with\n\n<!--pytest.mark.skip-->\n\n```\npip install betterbib\n```\n\nSee [here](https://github.com/texworld) for licensing information.\n\n#### Convert\n\n#### Sync\n\nSimply run\n\n<!--pytest.mark.skip-->\n\n```sh\nbetterbib sync in.bib\n```\n\nto sync your bibliography file with online sources. For example, the input\n\n```bibtex\n@article{wiles,\ntitle={Fermat Last Theorem},\ndoi={10.2307/2118559},\n}\n```\n\nis converted to\n\n```bibtex\n@article{wiles,\n number = {3},\n doi = {10.2307/2118559},\n pages = {443},\n source = {Crossref},\n volume = {141},\n author = {Wiles, Andrew},\n year = {1995},\n month = may,\n url = {https://doi.org/10.2307/2118559},\n issn = {0003-486X},\n journal = {The Annals of Mathematics},\n publisher = {JSTOR},\n title = {Modular Elliptic Curves and Fermat's Last Theorem},\n}\n```\n\nSee `-h`/`--help` for all options.\n\n<!--pytest.mark.skipif(sys.version_info < (3, 11), reason=\"Need Python 3.11+\")-->\n\n```sh\nbetterbib sync -h\n```\n\n<!--pytest-codeblocks: expected-output-ignore-whitespace-->\n\n```\nUsage: betterbib sync [-h] [-i] [-c N] [-s SRC] [-m MINIMUM_SCORE] [-q] [--debug]\n [--output-format {bibtex,biblatex,csl-json,ris}]\n infiles [infiles ...]\n\nPositional Arguments:\n infiles input bibliography files\n\nOptions:\n -h, --help show this help message and exit\n -i, --in-place modify infile in place\n -c, --num-concurrent-requests N\n number of concurrent HTTPS requests (default: 1)\n -s, --sources SRC sources to try (comma-separated, with order; default:\n crossref,dblp,pubmed)\n -m, --minimum-score MINIMUM_SCORE\n minimum score to count as a match (default: 0.0)\n -q, --quiet don't show progress info (default: show)\n --debug some debug output (default: false)\n --output-format {bibtex,biblatex,csl-json,ris}\n force output format (default: same as input)\n```\n\n#### Format\n\nAfter that, you can for example run\n\n```\nbetterbib format in.bib --sort-fields --align-values --journal-names short --abbrev-first-names\n```\n\nto get\n\n```bibtex\n@article{wiles,\n author = {Wiles, A.},\n doi = {10.2307/2118559},\n issn = {0003-486X},\n journal = {Ann. Math.},\n month = may,\n number = {3},\n pages = {443},\n publisher = {JSTOR},\n source = {Crossref},\n title = {Modular Elliptic Curves and Fermat's Last Theorem},\n url = {https://doi.org/10.2307/2118559},\n volume = {141},\n year = {1995},\n}\n```\n\n```sh\nbetterbib format -h\n```\n\n<!--pytest.mark.skipif(sys.version_info < (3, 11), reason=\"Need Python 3.11+\")-->\n\n```\nUsage: betterbib format [-h] [-i] [--drop DROP] [--journal-names {long,short,unchanged}] [--abbrev-first-names]\n [--sort-entries] [--sort-fields] [--doi-url-type {unchanged,old,new,short}]\n [--page-range-separator PAGE_RANGE_SEPARATOR] [--protect-title-capitalization]\n [--indent [INDENT]] [--align-values]\n infiles [infiles ...]\n\nPositional Arguments:\n infiles input BibTeX files\n\nOptions:\n -h, --help show this help message and exit\n -i, --in-place modify infile in place\n --drop DROP drop fields from entries (can be passed multiple times)\n --journal-names {long,short,unchanged}\n force full or abbreviated journal names (default: unchanged)\n --abbrev-first-names abbreviate first names in author lists etc. (default: false)\n --sort-entries sort entries alphabetically by BibTeX key (default: false)\n --sort-fields sort fields alphabetically (default: false)\n --doi-url-type {unchanged,old,new,short}\n DOI URL (new: https://doi.org/<DOI>, short: https://doi.org/abcde) (default: new)\n --page-range-separator PAGE_RANGE_SEPARATOR\n page range separator (int or string, default: unchanged)\n --protect-title-capitalization\n brace-protect names in titles (e.g., {Newton}; default: false)\n --indent [INDENT] indentation (int or string; default: 1)\n --align-values align field values (default: false)\n```\n\n#### Dereference DOIs\n\nGiven a DOI or a DOI URL, it's often useful to generate a bibliography entry for it. `betterbib doi-to` does just that.\n\n```sh\nbetterbib doi-to ris 10.1002/andp.19053221004\n```\n\n<!--pytest-codeblocks: expected-output-ignore-whitespace-->\n\n```ris\nTY - JOUR\nIS - 10\nDO - 10.1002/andp.19053221004\nSP - 891\nEP - 921\nDS - Crossref\nVL - 322\nAU - Einstein, A.\nDA - 1905/01\nUR - https://doi.org/10.1002/andp.19053221004\nSN - 0003-3804\nSN - 1521-3889\nJF - Annalen der Physik\nJO - Ann. Phys.\nPB - Wiley\nTI - Zur Elektrodynamik bewegter K\u00f6rper\nER -\n```\n",
"bugtrack_url": null,
"license": null,
"summary": "Better bibliography data",
"version": "7.3.1",
"project_urls": {
"Homepage": "https://github.com/texworld/betterbib",
"Issues": "https://github.com/texworld/betterbib/issues"
},
"split_keywords": [
"bibtex",
" latex"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "cc11275f40f7ebfb10f822a689fe069fc30ae91bd17804122388a6d48afe8ff7",
"md5": "4e0d5c73da3e1048b7bae0e40883cef5",
"sha256": "6d1978095513344172341551031d44860f8d904574bf7081d03615cc6cf21775"
},
"downloads": -1,
"filename": "betterbib-7.3.1-py3-none-any.whl",
"has_sig": false,
"md5_digest": "4e0d5c73da3e1048b7bae0e40883cef5",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.9",
"size": 3169845,
"upload_time": "2025-01-02T18:12:47",
"upload_time_iso_8601": "2025-01-02T18:12:47.269626Z",
"url": "https://files.pythonhosted.org/packages/cc/11/275f40f7ebfb10f822a689fe069fc30ae91bd17804122388a6d48afe8ff7/betterbib-7.3.1-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2025-01-02 18:12:47",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "texworld",
"github_project": "betterbib",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"lcname": "betterbib"
}