Using devtools to host code from GitHub can be done using the following steps:
- Add some useful metadata and license files to the package:
usethis::use_mit_license(name = "Dan MacLean")
usethis::use_readme_rmd()
usethis::use_lifecycle_badge("Experimental")
usethis::use_version()
- Add to the list of dependencies that will be automatically installed when your package is installed:
usethis::use_package("ggplot2")
- Automatically set up the local Git repository and get GitHub credentials:
usethis::use_git()
usethis::browse_github_token()
usethis::use_github()
- Install the package from GitHub:
devtools::install_github("user/repo")