The goal of nat.devtools is to enable efficient development of R packages according to natverse conventions.
nat.devtools uses the usethis package to automate a number of development tasks. Please ensure that you have configured usethis as recommended.
You can do this by typing the following in your R session:
nat.devtools::use_nat_description_defaults()
to edit your .Rprofile
file. Mine looks like this:
options(
usethis.full_name = "Gregory Jefferis",
usethis.protocol = "ssh",
usethis.description = list(
`Authors@R` = 'person("Gregory","Jefferis", email="[email protected]",
role=c("aut", "cre"), comment = c(ORCID = "0000-0002-0587-9355"))',
License = "GPL-3",
Encoding = "UTF-8",
Language = "en-GB"
)
)
Once you're all set up, then the easiest way to use the package to configure your current project is to do:
nat.devtools::nat_setup_package()
This configures almost everything about a project and will ask interactive questions to determine if you want to upgrade / overwrite different files.
If you switch between different projects in the same session, then you must do:
usethis::proj_set()
to set the active project to the current directory.