xopen

Open a file in its default application, across platforms

  • xopen

Downloads in past

Stats

StarsIssuesVersionUpdatedCreatedSize
xopen
1.0.06 years ago6 years agoMinified + gzip package size for xopen in KB

Readme

xopen - Open a file with the default application
xopen provides a dead-simple Promise API for opening files from Node on Windows, macOS, and Linux:

xopen(filepath)

filepath is a path to the file you wish to open. When you call xopen(), it returns a Promise that is resolved with the contents of stdout if the application successfully opens, and is rejected with an error if the application fails to open.
It's that easy.