open
open a file or url in the user's preferred application
Last updated 5 years ago by pwnall .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install open 
SYNC missed versions from official npm registry.

open

Open a file or url in the user's preferred application.

Usage

var open = require("open");
open("http://www.google.com");

open taks an optional argument specifying the program to be used to open the file or URL.

open("http://www.google.com", "firefox");

Installation

npm install open

How it works

  • on win32 uses start
  • on darwin uses open
  • otherwise uses the xdg-open script from freedesktop.org

Warning

The same care should be taken when calling open as if you were calling child_process.exec directly. If it is an executable it will run in a new shell.

Current Tags

  • 0.0.5                                ...           latest (5 years ago)

5 Versions

  • 0.0.5                                ...           5 years ago
  • 0.0.4                                ...           5 years ago
  • 0.0.3                                ...           6 years ago
  • 0.0.2                                ...           7 years ago
  • 0.0.0                                ...           7 years ago
Maintainers (2)
Downloads
Today 1,609
This Week 24,053
This Month 70,943
Last Day 3,791
Last Week 27,586
Last Month 114,452
Dependencies (0)
None
Dev Dependencies (1)
Dependents (2183)

Copyright 2014 - 2018 © taobao.org |