R/util.R

Defines functions get_os

get_os <- function(){
    sysinf <- Sys.info()
    if (!is.null(sysinf)) {
        os <- sysinf['sysname']
        if (os == 'Darwin')
            os <- "osx"
    } else {## mystery machine
        os <- .Platform$OS.type
        if (grepl("^darwin", R.version$os))
            os <- "osx"
        if (grepl("linux-gnu", R.version$os))
            os <- "linux"
    }
    tolower(os)
}

Try the JuliaCall package in your browser

Any scripts or data that you put into this service are public.

JuliaCall documentation built on Sept. 8, 2022, 5:10 p.m.