1
0
Fork 0
mirror of https://github.com/jashkenas/coffeescript.git synced 2022-11-09 12:23:24 -05:00

node conversion finished, narwhal removed.

This commit is contained in:
Jeremy Ashkenas 2010-01-29 23:30:54 -05:00
parent e08e99a403
commit f5a37035cf
48 changed files with 208 additions and 357 deletions

View file

@ -17,4 +17,17 @@
coffee.write(code);
return coffee.close();
};
exports.compile_files = function compile_files(paths, callback) {
var coffee, js;
js = '';
coffee = process.createChildProcess('coffee', ['--print'].concat(paths));
coffee.addListener('output', function(results) {
if ((typeof results !== "undefined" && results !== null)) {
return js += results;
}
});
return coffee.addListener('exit', function() {
return callback(js);
});
};
})();