Package Exports
- promise-child
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (promise-child) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
promise-child
Create a promise from a ChildProcess.
Install
npm install promise-child --saveUse
var promisify = require("promise-child");
var spawn = require("child_process").spawn;
var child = spawn("echo", ["hello"]);
promisify(child).then(function(code){
// code === 0
});
promisify(child, {
stdout: true
}).then(function(result){
// result.code === 0
// result.stdout -> Whatever stdout spit out.
});License
BSD 2 Clause