This function identifies the operating system on which R is running. It returns a character string indicating the OS type, which can be one of the following: "windows", "macos", or "linux".
Value
A character string representing the operating system: "windows" for Windows OS, "macos" for macOS, "linux" for Linux.
Examples
# Get the current operating system
os_type <- get_os()
print(os_type)
#> [1] "linux"