node-exec
v0.1.1
Published
Execute shell commands from NodeJS
Downloads
37
Maintainers
Readme
node-exec
Execute shell commands from NodeJS
How to use?
Simple, just install it, require it and use it
- Install it:
npm install --save node-exec
- Require it:
var shell = require('node-exec');
- Usage:
let cmd = "pwd";
/**
* @params {string} cmd (required)
*/
shell.run(cmd).then(function(res){
// res: object with keys {code,result} or {code,error}
console.dir(res);
});