df2bib: Export a BibTeX 'tibble' to a .bib file

Description Usage Arguments Value Author(s) References See Also Examples

View source: R/df2bib.R

Description

The BibTeX tibble is written to a .bib file

Usage

1
df2bib(x, file = "", append = FALSE)

Arguments

x

tibble, in the format as returned by bib2df.

file

character, file path to write the .bib file. An empty character string writes to stdout (default).

append

logical, if TRUE the tibble will be appended to an existing file.

Value

file as a character string, invisibly.

Author(s)

Thomas J. Leeper

References

http://www.bibtex.org/Format/

See Also

bib2df

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
# Read from .bib file:
path <- system.file("extdata", "bib2df_testfile_3.bib", package = "bib2df")
bib <- bib2df(path)

# Write to .bib file:
# bibFile <- tempfile()
# df2bib(bib, bibFile)

# Use `append = TRUE` to add lines to an existing .bib file:
# df2bib(bib, bibFile, append = TRUE)

Example output

Warning message:
`as_data_frame()` is deprecated as of tibble 2.0.0.
Please use `as_tibble()` instead.
The signature and semantics have changed, see `?as_tibble`.
This warning is displayed once every 8 hours.
Call `lifecycle::last_warnings()` to see where this warning was generated. 

bib2df documentation built on May 23, 2019, 1:03 a.m.