const bash = (() => { const bashProc = spawn("bash"); bashProc.stdout.on("data", (data: string) => { console.log(`stdout: ${data}`); }); bashProc.stderr.on("data", (err: string) => { console.error(`stderr: ${err}`); throw Error(err); }); bashProc.on("close", (code: string) => { console.log(`child process exited with code ${code}`); }); return bashProc.stdin.write;})();bash('echo lll');
Deno.run