Skip to content

Commit 5019824

Browse files
Use 'exec'.
1 parent 230ccd6 commit 5019824

File tree

1 file changed

+2
-24
lines changed

1 file changed

+2
-24
lines changed

Jakefile.js

Lines changed: 2 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -365,18 +365,7 @@ compileFile(/*outfile*/configureNightlyJs,
365365
/*callback*/ function () {
366366
var cmd = "node " + configureNightlyJs + " " + packageJson + " " + programTs;
367367
console.log(cmd);
368-
var ex = jake.createExec([cmd]);
369-
// Add listeners for output and error
370-
ex.addListener("stdout", function(output) {
371-
process.stdout.write(output);
372-
});
373-
ex.addListener("stderr", function(error) {
374-
process.stderr.write(error);
375-
});
376-
ex.addListener("cmdEnd", function() {
377-
complete();
378-
});
379-
ex.run();
368+
exec(cmd, completeHandler, errorHandler)
380369
});
381370

382371
task("setDebugModeTrue", function() {
@@ -387,18 +376,7 @@ desc("Configure, build, test, and publish the nightly release.");
387376
task("publish-nightly", [configureNightlyJs, "LKG", "clean", "setDebugModeTrue", "runtests"], function () {
388377
var cmd = "npm publish";
389378
console.log(cmd);
390-
var ex = jake.createExec([cmd]);
391-
// Add listeners for output and error
392-
ex.addListener("stdout", function(output) {
393-
process.stdout.write(output);
394-
});
395-
ex.addListener("stderr", function(error) {
396-
process.stderr.write(error);
397-
});
398-
ex.addListener("cmdEnd", function() {
399-
complete();
400-
});
401-
ex.run();
379+
exec(cmd, completeHandler, errorHandler)
402380
}, {async: true});
403381

404382
// Local target to build the compiler and services

0 commit comments

Comments
 (0)