Learn R Programming

radiant (version 0.1.95)

mac_launcher: Create a launcher for Mac (.command)

Description

Create a launcher for Mac (.command)

Usage

mac_launcher(app = c("marketing", "quant", "base"))

Arguments

app
App to run when the desktop icon is double-clicked ("marketing", "quant", or "base"). Default is "marketing"

Details

On Mac a file named 'radiant.command' will be put on the desktop. Double-click the file to launch the specified Radiant app

Examples

Run this code
if (interactive()) {
  if(Sys.info()["sysname"] != "Darwin") {
    mac_launcher()
    fn <- paste0("/Users/",Sys.getenv("USER"),"/Desktop/radiant.command")
    if(!file.exists(fn))
      stop("Mac launcher not created")
    else
      unlink(fn)
  }
}

Run the code above in your browser using DataLab