跳转到主要内容

将包含(key -> DOI)对的yaml文件转换为带有正确期刊缩写的bib文件。

项目描述

yaml2bib:使用DOI将yaml文件转换为带有正确期刊缩写的bib文件。

license tests codecov docs version PyPI - Python Version

安装

pip install yaml2bib

用法

用作命令行工具

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.

示例调用我的论文

yaml2bib \
  --bib_fname "dissertation.bib" \
  --dois_yaml "*/*.yaml" \
  --replacements_yaml "replacements.yaml" \
  --static_bib "chapter_*/not_on_crossref.bib" \
  --email "bas@nijho.lt"

或作为库

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",
)

许可证

MIT许可证

贡献者

  • Bas Nijholt

项目详情


下载文件

下载适合您平台的文件。如果您不确定选择哪个,请了解更多关于安装包的信息。

源分布

yaml2bib-0.1.3.tar.gz (6.8 kB 查看散列值)

上传时间:

构建分布

yaml2bib-0.1.3-py3-none-any.whl (7.2 kB 查看散列值)

上传时间: Python 3

由以下支持