nodejs core exec() function thunk wrapper for "co"
JavaScript
Latest commit f7d0416 Apr 22, 2014 @tj Merge pull request #4 from juliangruber/add/repository
add repository
Failed to load latest commit information.
test
.gitignore
History.md
Makefile
Readme.md
example.js
index.js
package.json

Readme.md

co-exec

Node core exec() wrapped to return a thunk for co.

Installation

$ npm install co-exec

Example

Do some stuff with git:

var co = require('co');
var exec = require('co-exec');

co(function *(){
  var commit = yield exec('git rev-parse HEAD');
  var commits = yield exec('git rev-list master | wc -l');
  console.log('the latest commit is %s, with a total of %s', commit.slice(0, 5), commits.trim());
});

License

MIT