command
command
npm i command
command

command

A Node.js chainable, promise-based utility for running commands with child_process.spawn

by UmbraEngineering

0.0.5 (see all)License:MITTypeScript:Not Found
npm i command
Readme

command

A Node.js chainable, promise-based utility for running commands with child_process.spawn

Install

$ npm install command

Usage

var command = require('command');

command.open('/some/directory/path')
    .on('stdout', command.writeTo(process.stdout))
    .on('stderr', command.writeTo(process.stderr))
    .chdir('..')
    .exec('ls')
    .then(function() {
        var stdout = this.lastOutput.stdout;
        if (! stdout.trim().length) {
            console.warn('No files found!');
        }
    });
No alternatives found
No tutorials found
Add a tutorial
No dependencies found

Rate & Review

100
No reviews found
Be the first to rate