PexitCode
Bun

property

child_process.ChildProcessByStdio.exitCode

readonly exitCode: null | number

The subprocess.exitCode property indicates the exit code of the child process. If the child process is still running, the field will be null.

When the child process is terminated by a signal, subprocess.exitCode will be null and subprocess.signalCode will be set. To get the corresponding POSIX exit code, use util.convertProcessSignalToExitCode(subprocess.signalCode).