NodeJS - ExecFile

var child = cp.execFile(path.join(process.env.SCRIPTS_ROOT || "", process.env.SCRIPT_APPLY_DAILY_UPDATES || ""), args, function(err:any, stdout:any, stderr:any) { // Node.js will invoke this callback when process terminates. console.log("--- Process Complete ---"); console.log(stdout); stdoutFinal = stdout; }); child.on('close', (code: any) => { console.log("Close Code: " + code); }); child.stdout.on('data', function (data: any) { stdoutFinal.push(data); });

Be the first to comment

You can use [html][/html], [css][/css], [php][/php] and more to embed the code. Urls are automatically hyperlinked. Line breaks and paragraphs are automatically generated.