Convert a yaml file containing (key -> DOI) pairs to bib file with the correct journal abbreviations.
Project description
📘 yaml2bib: Convert YAML to BibTeX with Correct Journal Abbreviations Using Only DOIs 🚀
Introducing 🌟 yaml2bib, an easy-to-use and powerful Python library and command-line tool that seamlessly converts YAML files to BibTeX format, all while maintaining the correct journal abbreviations using only DOIs! 🎉
Whether you're a researcher or a student, yaml2bib will simplify and streamline your bibliography management process. With an intuitive interface, customizable options, and compatibility as both a library and a command-line tool, it's never been more convenient to create and maintain your citation records.
Say goodbye to manual conversions and hello to yaml2bib! 🚀
🛠️ Installation
pip install yaml2bib
🚀 Usage
Command Line Tool
Check out the help message yaml2bib --help:
Usage: yaml2bib [OPTIONS]
Options:
--bib_fname TEXT Output file. (default: 'dissertation.bib')
--dois_yaml TEXT The `key: doi` YAML file, may contain wildcards
(*). (default: 'bib.yaml', example: '*/*.yaml')
--replacements_yaml TEXT Replacements to perform, might be None. (default:
None, example: 'replacements.yaml')
--static_bib TEXT Static bib entries, might be None, may contain
wildcards (*). (default: None, example:
'chapter_*/not_on_crossref.bib')
--doi2bib_database TEXT The doi2bib database folder 📁 to not query doi.org
more than needed. (default: 'yaml2bib-doi2bib.db')
--crossref_database TEXT The Crossref database folder 📁 to not query
crossref.org more than needed. (default:
'yaml2bib-doi2bib.db')
--email TEXT E-mail 📧 for crossref.org, such that one can make
more API calls without getting blocked. (default:
'anonymous', example: 'bas@nijho.lt')
--help Show this message and exit.
Example invocation for Bas Nijholt's thesis:
yaml2bib \
--bib_fname "dissertation.bib" \
--dois_yaml "*/*.yaml" \
--replacements_yaml "replacements.yaml" \
--static_bib "chapter_*/not_on_crossref.bib" \
--email "bas@nijho.lt"
Python Library
from yaml2bib import yaml2bib
yaml2bib(
bib_fname="dissertation.bib",
dois_yaml="*/*.yaml",
replacements_yaml="replacements.yaml",
static_bib="chapter_*/not_on_crossref.bib",
email="bas@nijho.lt",
)
🌟 Full Example
Check out the examples
Convert with:
yaml2bib \
--bib_fname "example.bib" \
--dois_yaml "example.yaml" \
--replacements_yaml "replacements.yaml" \
--static_bib "not_on_crossref.bib" \
--email "bas@nijho.lt"
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file yaml2bib-0.2.0.tar.gz.
File metadata
- Download URL: yaml2bib-0.2.0.tar.gz
- Upload date:
- Size: 9.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ab70b0028929fc3f69dd6ada76cde627b8a3469e36628823b3bd92d673329c80
|
|
| MD5 |
7cd3f33763c45a7e5af12aa7c0b67ae6
|
|
| BLAKE2b-256 |
7a15605e9b343651ac46b026bb6d8e3dcf7ed030710a538dad124c5767c8a772
|
Provenance
The following attestation bundles were made for yaml2bib-0.2.0.tar.gz:
Publisher:
pythonpublish.yml on basnijholt/yaml2bib
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
yaml2bib-0.2.0.tar.gz -
Subject digest:
ab70b0028929fc3f69dd6ada76cde627b8a3469e36628823b3bd92d673329c80 - Sigstore transparency entry: 152780558
- Sigstore integration time:
-
Permalink:
basnijholt/yaml2bib@659a682d58bebe1cb1cc33c483a4822ab7968449 -
Branch / Tag:
refs/tags/v0.2.0 - Owner: https://github.com/basnijholt
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
pythonpublish.yml@659a682d58bebe1cb1cc33c483a4822ab7968449 -
Trigger Event:
release
-
Statement type:
File details
Details for the file yaml2bib-0.2.0-py3-none-any.whl.
File metadata
- Download URL: yaml2bib-0.2.0-py3-none-any.whl
- Upload date:
- Size: 7.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
cdbc5145ab9267e8406e0c83e36c2b8f8984c3ce208dc247cd85fb9c661dfcef
|
|
| MD5 |
55099148547760d5ddcb54dd4f79fccf
|
|
| BLAKE2b-256 |
f427c401771cc3b95cec286ae18cfe71519f08a58be1a0a15580578fc46cb29d
|
Provenance
The following attestation bundles were made for yaml2bib-0.2.0-py3-none-any.whl:
Publisher:
pythonpublish.yml on basnijholt/yaml2bib
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
yaml2bib-0.2.0-py3-none-any.whl -
Subject digest:
cdbc5145ab9267e8406e0c83e36c2b8f8984c3ce208dc247cd85fb9c661dfcef - Sigstore transparency entry: 152780560
- Sigstore integration time:
-
Permalink:
basnijholt/yaml2bib@659a682d58bebe1cb1cc33c483a4822ab7968449 -
Branch / Tag:
refs/tags/v0.2.0 - Owner: https://github.com/basnijholt
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
pythonpublish.yml@659a682d58bebe1cb1cc33c483a4822ab7968449 -
Trigger Event:
release
-
Statement type: