import { exec } from "../index.js"
exec("node -v").then(console.log) // 13.5.0
import { spawn } from "../index.js"
spawn("node", ["-v"]).then(console.log) // 13.5.0
inherit stdout from the master process
Notice. stdoutInherit: true
makes childprocess alwasy return null.
import { spawn } from "../index.js"
spawn("node", ["-e", "console.log(require('tty').isatty(1))"], { stdoutInherit: true }).then(console.log) // null
// true