The rstudioapi package provides access the RStudio API (if available) and provides informative error messages when it's not.
Installed Size: 500.7 kB Architectures: all