Permalink
Browse files

adds console.log and console.error for git push

  • Loading branch information...
1 parent 9499493 commit ed0d8ce8e150326021afe63ef001c0c93bffd62f @tblobaum tblobaum committed Mar 21, 2012
Showing with 9 additions and 0 deletions.
  1. +9 −0 lib/git.js
View
@@ -22,6 +22,15 @@ exports.push = function push (remote, branch, cb) {
});
var ps = spawn('git', [ 'push', remote, branch ]);
+
+ ps.stdout.on('data', function (data) {
+ console.log(String(data));
+ });
+
+ ps.stderr.on('data', function (data) {
+ console.error(String(data));
+ });
+
ps.on('exit', function (code, sig) {
if (code !== 0) cb(new Error('caught signal ' + sig + ', code ' + code))
else cb(null)

0 comments on commit ed0d8ce

Please sign in to comment.