forked from remindmodel/remind
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.Rprofile
20 lines (17 loc) · 839 Bytes
/
.Rprofile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
source("renv/activate.R")
if (!"https://rse.pik-potsdam.de/r/packages" %in% getOption("repos")) {
options(repos = c(getOption("repos"), pik = "https://rse.pik-potsdam.de/r/packages"))
}
# bootstrapping, will only run once after remind is freshly cloned
if (isTRUE(rownames(installed.packages(priority = "NA")) == "renv")) {
message("R package dependencies are not installed in this renv, installing now...")
renv::install("yaml", prompt = FALSE) # yaml is required to find dependencies in Rmd files
renv::hydrate() # auto-detect and install all dependencies
renv::snapshot(prompt = FALSE) # create renv.lock
message("Finished installing R package dependencies.")
}
# source global .Rprofile (very important to load user specific settings)
# DO NOT EDIT THIS LINE!
if (file.exists("~/.Rprofile")) {
source("~/.Rprofile")
}