0.1.1 • Published 5 years ago

launch-code-editor v0.1.1

Weekly downloads
6
License
MIT
Repository
github
Last release
5 years ago

launch-code-editor

Open file with line numbers in editor from Node.js.

This package is forked from launch-editor

support launch specified editor in process.

Why

Changed too much and deviated from the original design of launch-editor. So created this package to work out cases when you need launch specified editor in process

Usage

const launch = require('launch-editor')

launch(
  // filename:line:column
  // both line and column are optional
  'foo.js:12:34',
  // try specific editor bin first (optional)
  'code',
  // callback if failed to launch (optional)
  (fileName, errorMsg) => {
    // log error if any
  }
)

Supported editors

ValueEditorLinuxWindowsOSX
atomAtom
codeVisual Studio Code
code-insidersVisual Studio Code Insiders
sublimeSublime Text
webstormWebStorm