set_PATH <- function(PATH = "C:\\rtools40\\mingw64\\bin; C:\\rtools40\\usr\\bin") {
if (Sys.info()[["sysname"]] == "Windows") {
if (Sys.which("gcc") == "") { # echo $PATH
Sys.setenv(PATH = paste(PATH, Sys.getenv("PATH"), sep = ";"))
} # PATH=$PATH:/c/Rtools/mingw_32/bin; export PATH
} # PATH=$PATH:/c/MinGW/msys/1.0/local/bin
}
.onLoad <- function(...) {
set_PATH()
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.