node_executor

1.0.1 • Public • Published

node_executor

executes a child process and buffers the output as string for a callback.

var fs = require('fs');
var Executor = require('node_executor');

const args = process.argv.slice(2);

const cmd = args[0];
const param = args.slice(1);

x = new Executor(cmd, param);

x.chop(function(v) {
  fs.appendFile('./test.log', v, function () {
    console.log(`appended to ${v} to file`):
  });
});

Package Sidebar

Install

npm i node_executor

Weekly Downloads

3

Version

1.0.1

License

ISC

Unpacked Size

6.53 kB

Total Files

6

Last publish

Collaborators

  • ruijs