query_bib: Query bibliography

Description Usage Arguments Details Value See Also

View source: R/query_bib.R

Description

Search entries in a bibliography.

Usage

1
2
3
4
5
6
query_bib(x, bib_file = getOption("citr.bibliography_path"),
  cache = TRUE,
  use_betterbiblatex = getOption("citr.use_betterbiblatex"),
  betterbiblatex_format = getOption("citr.betterbiblatex_format"),
  exclude_betterbiblatex_library = getOption("citr.exclude_betterbiblatex_library"),
  encoding = getOption("citr.encoding"))

Arguments

x

Character. Search terms used to filter bibliography (by author, year, title, and journal fields); Regex is supported.

bib_file

Character. Path to Bib(La)TeX-file. See details.

cache

Logical. If cache = TRUE cached bibliography is used, if available. If cache = FALSE bibliography is re-imported on every function call.

use_betterbiblatex

Logical. If use_betterbiblatex = TRUE references are imported from Zotero/Juris-M.

betterbiblatex_format

Character. Bibliography format to export from Zotero/Juris-M. Can be either "bibtex" or "biblatex". Ignored if use_betterbiblatex = FALSE. Requires that the Better BibTeX is installed and Zotero/Juris-M is running.

exclude_betterbiblatex_library

Character. A vector of Zotero/Juris-M library names not to query.

encoding

Character. Encoding of the Bib(La)TeX-file.

Details

The path to the BibTeX-file can be set in the global options and is set to references.bib when the package is loaded. Once the path is changed in the RStudio addin, the global option is updated. If use_betterbiblatex = TRUE references are imported from Zotero/Juris-M rather than from the Bib(La)TeX-file. The Bib(La)TeX-file is then updated to include the inserted reference.

Value

Returns list of class BibEntry including all matching bibliography entries.

See Also

md_cite, insert_citation


awconway/citippy documentation built on Feb. 23, 2020, 7:41 p.m.