xopen v1.0.0

0

Monthly downloads

0th

Percentile

Open System Files, 'URLs', Anything

Cross platform solution to open files, directories or 'URLs' with their associated programs.

Readme

xopen

Open System Files, URLs, Anything

Linux Build Status Windows Build status CRAN RStudio mirror downloads

Cross platform solution to open files, directories or URLs with their associated programs. Inspired by shell.exec(), https://github.com/pwnall/node-open and https://github.com/sindresorhus/opn

Installation

Once released, you can install xopen from CRAN:

install.packages("xopen")

Usage

library(xopen)

Open a file:

xopen("test.R")

Open a URL:

xopen("https://ps.r-lib.org")

URL with given app:

chrome <- function() {
  switch(
    get_os(),
    win = "Chrome",
    macos = "google chrome",
    other = "google-chrome")
}
xopen("https://processx.r-lib.org", app = chrome())

Open a given app (or switch to it, if already open):

xopen(app = chrome())

App and arguments. (You need to quit Chrome for this to work):

xopen(app = c(chrome(), "--incognito", "https://github.com"))

License

MIT © RStudio

Functions in xopen

Name Description
xopen Open a file, directory or URL
wait_for_finish Wait for a process to finish
No Results!

Last month downloads

Details

License MIT + file LICENSE
LazyData true
URL https://github.com/r-lib/xopen#readme
BugReports https://github.com/r-lib/xopen/issues
RoxygenNote 6.1.0
Encoding UTF-8
NeedsCompilation no
Packaged 2018-09-10 20:47:53 UTC; gaborcsardi
Repository CRAN
Date/Publication 2018-09-17 13:10:03 UTC

Include our badge in your README

[![Rdoc](http://www.rdocumentation.org/badges/version/xopen)](http://www.rdocumentation.org/packages/xopen)