2 Package setup
Every R package needs a DESCRIPTION file, so we start by specifying this information:
::create_package(
usethispath = ".",
fields = list(
Package = params$package_name,
Version = "0.0.0.9000",
Title = "A Package Defined in a Bookdown",
Description = "This package uses litr to define an R package through writing a bookdown.",
`Authors@R` = person(
given = "First",
family = "Last",
email = "you@gmail.com",
role = c("aut", "cre")
)
)
)::use_mit_license(copyright_holder = "F. Last") usethis
Although it’s not required, it can be nice to add some package-level documentation. This is what will show up when someone types package?<your-package-name>
in the console.
#' A Package Defined in a Bookdown
#'
#' This package uses `litr` to define an R package through writing a `bookdown`.
#'
#' @docType package