1.1.0 • Published 8 years ago

stdin-line-open v1.1.0

Weekly downloads
2
License
MIT
Repository
github
Last release
8 years ago

stdin-line-open

npm Build Status Coverage Status Dependency Status npm GitHub license

Read line from stdin and trigger open job if line is matched

Install

npm i -D stdin-line-open

Usage

import createStdinLineOpen from 'stdin-line-open';

// create a stdin listener
const stdinLineOpen = createStdinLineOpen({
  match: 'open',
  open: 'http://google.com'
});

// starts to listen stdin.
// input "open" and enter on CLI, then it'll
// open "http://google.com" in browser for you.
stdinLineOpen();

License

MIT © Archie Lee