knitr::opts_chunk$set(echo = TRUE, eval = FALSE)

Install Starting packages

renv::install('usethis')
renv::install('gitcreds')

GITHUB_PAT

Make sure PAT is accessible in the package. Run usethis::edit_r_profile('project') to open up the project R profile and then add the following line so that the PAT is accessible to {remotes} and {renv} as a environmental variable (GITHUB_PAT).

#make sure to leave a blank line at the end of the file when you save it
Sys.setenv('GITHUB_PAT' = gitcreds::gitcreds_get()[['password']])

Setup ROxygen

Delete the default NAMESPACE document
Then run:

renv::install('devtools')
devtools::document()

Add packages to imports:

Adds the relevant lines to the package DESCTIPTION file:

usethis::use_package('renv')
usethis::use_package('gitcreds')
usethis::use_dev_package('marcR', remote = 'github::MARC-KC/marcR')
usethis::use_pipe()
usethis::use_package('usethis', type = 'Suggests')#for dataset update using updatePublicStaticDatasets()
usethis::use_package('dplyr')
# usethis::use_dev_package('Covid19MARCInternal', type = 'Suggests', remote = 'github::MARC-KC/Covid19MARCInternal')
usethis::use_package('rlang')
usethis::use_package('tibble')
usethis::use_package('purrr')
usethis::use_package('glue')
usethis::use_package('crayon')
usethis::use_package('stringr')
usethis::use_package('lubridate')
usethis::use_package('tidyr')


MARC-KC/Covid19MARCData documentation built on April 7, 2022, 11:43 a.m.