1.0.0 • Published 9 months ago

open-default v1.0.0

Weekly downloads
-
License
MIT
Repository
-
Last release
9 months ago

open-default

This is a simple wrapper script designed to open a file in the default application for each operating system. It is particularly useful if you want to add a script to your package.json for opening files.

Unlike other solutions, such as open-cli, this script is concise, consisting of only a few lines of code, and has no dependencies.

Installation

npm install open-default --save-dev

Usage

open-default <path>

Commands Used

The following commands are utilized to open a file based on the operating system:

Operating SystemCommand
Windowsstart
macOSopen
Linuxxdg-open
FreeBSDxdg-open
OpenBSDxdg-open
1.0.0

9 months ago