Show how to configure R for SpeedGoat packages
spdgt_setup.RdPrints the two things a new user needs and offers to open the files they go in:
.Rprofile— the SpeedGoat package repository, soinstall.packages("spdgt.auth")resolves at all..Renviron—SPDGT_REGION, only if you work with the Canadian deployment.
Both files live in R's home directory, which is not always the shell's:
on Windows it is usually Documents, so a file placed beside the shell's
~ is silently never read. usethis locates them properly, which is why
this offers to open them rather than telling you a path to go and find.
It prints rather than writes. These are personal files that may already
hold hand-written configuration, and silently appending to someone's
.Rprofile is not a thing a package should do.
Usage
spdgt_setup(open = rlang::is_interactive())See also
api_url() to confirm which region a session resolves to
Examples
spdgt_setup(open = FALSE)
#>
#> ── Installing SpeedGoat packages ──
#>
#> Add this to your .Rprofile:
#> options(repos = c(
#> SPDGT = "https://nexus.spdgt.com/repository/public-group/",
#> CRAN = "https://cloud.r-project.org"
#> ))
#> Both entries are needed. `CRAN` is where dependencies come from, and R resolves
#> each package to the highest version across the repos you list.
#>
#> ── Working with the Canadian deployment ──
#>
#> Only if your projects live in Canada. Add this to your .Renviron, then restart
#> R:
#> SPDGT_REGION=ca
#> Leave it unset for the United States. Check it took effect with
#> `spdgt.auth::auth_status()`.