cran_repo: Return a CRAN repo: The user-default, or RStudio's

Description Usage Value

Description

Package installation on remote machines depends on a CRAN repo, which can be tricky to set non-interactively. This simple wrapper function looks to see if a default CRAN mirror has already been set. If it has, it is returned. If not, fallback is returned.

Usage

1
cran_repo(fallback = "https://cran.rstudio.com/")

Value

Either fallback, or the result of getOption("repos")["CRAN"]


brendan-r/brocks documentation built on May 13, 2019, 5:08 a.m.