Skip to content

Commit

Permalink
Exit with correct code
Browse files Browse the repository at this point in the history
Fixes #38

So when I run `fleet exec -- npm test` I can actually see when my tests fail!
  • Loading branch information
Raynos committed Oct 19, 2012
1 parent 0f7a107 commit 1526c37
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion bin/exec.js
Expand Up @@ -71,7 +71,10 @@ function spawn (hub, opts) {
if (procs[proc.drone] !== proc.id) return;
console.log('(' + proc.drone + '#' + proc.id + ' exited)');

if (--pending === 0) p.hub.close();
if (--pending === 0) {
p.hub.close();
process.exit(code);
}
});
});
});
Expand Down

0 comments on commit 1526c37

Please sign in to comment.