Nietzsche's Preposterous Moustache
Meet npm Pro: unlimited public & private packages + package-based permissions.Learn more »

runscript

1.4.0 • Public • Published

runscript

NPM version build status appveyor build status Test coverage David deps npm download

Run script easy!

Installation

$ npm install runscript

Quick start

const runScript = require('runscript');
 
runScript('node -v', { stdio: 'pipe' })
  .then(stdio => {
    console.log(stdio);
  })
  .catch(err => {
    console.error(err);
  });

run with timeout

Run user script for a maximum of 10 seconds.

const runScript = require('runscript');
 
runScript('node user-script.js', { stdio: 'pipe' }, { timeout: 10000 })
  .then(stdio => {
    console.log(stdio);
  })
  .catch(err => {
    console.error(err);
  });

License

MIT

Install

npm i runscript

DownloadsWeekly Downloads

8,703

Version

1.4.0

License

MIT

Unpacked Size

9.84 kB

Total Files

6

Last publish

Collaborators

  • avatar
  • avatar
  • avatar
  • avatar