R/onload.R

Defines functions .onLoad

.onLoad <- function(libname, pkgname) { # nocov start
  op <- options()
  op_citr <- list(
    citr.bibliography_path = "./references.bib"
    , citr.bibliography_cache = NULL
    , citr.citation_key_cache = NULL
    , citr.use_betterbiblatex = FALSE
    , citr.exclude_betterbiblatex_library = NULL
    , citr.betterbiblatex_format = "bibtex"
    , citr.bib_file_last_modified = Sys.time()
    , citr.bib_file_cache = NULL
    , citr.update_bib = "./references.bib"
    , citr.parent_documents = c("index.Rmd", "master.Rmd")
    , citr.encoding = "UTF-8"
  )
  toset <- !(names(op_citr) %in% names(op))
  if(any(toset)) options(op_citr[toset])

  invisible()
} # nocov end

Try the citr package in your browser

Any scripts or data that you put into this service are public.

citr documentation built on Aug. 19, 2019, 5:03 p.m.