Skip to content

Commit fba84ee

Browse files
committed
updated .Rprofile
1 parent 7ff4028 commit fba84ee

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

.Rprofile

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,23 @@
99
# .libPaths() already includes site library for default R version.
1010
.libPaths(c(.libPaths(), .Library.site))
1111

12+
# The remotes package is installed to install httpgd from GitHub
13+
# The gdiff package is installed to support visual difference testing
14+
15+
# Configure r-universe for binary package installations dynamically
16+
linux_binary_repo <- function(universe){
17+
runiverse <- sprintf('r-universe.dev/bin/linux/%s-%s/%s/',
18+
system2('lsb_release', '-sc', stdout = TRUE),
19+
R.version$arch,
20+
substr(getRversion(), 1, 3))
21+
sprintf('https://%s.%s', universe, runiverse)
22+
}
23+
24+
# Set repos for CRAN and nx10 (httpgd) to use r-universe linux binaries
25+
options(repos = c(
26+
cran = linux_binary_repo("cran")
27+
))
28+
1229
# For PNG graphics uncomment following lines
1330
# options(vsc.use_httpgd = FALSE,
1431
# vsc.dev.args = list(width = 800, height = 600))

0 commit comments

Comments
 (0)