You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
10 lines
329 B
10 lines
329 B
is_windows <- function() .Platform$OS.type == "windows"
|
|
is_mac <- function() Sys.info()[["sysname"]] == "Darwin"
|
|
is_linux <- function() Sys.info()[["sysname"]] == "Linux"
|
|
|
|
platform <- function() {
|
|
if (is_windows()) return("win")
|
|
if (is_mac()) return("mac")
|
|
if (is_linux()) return("linux")
|
|
stop("unknown platform")
|
|
}
|