Skip to main content

exit_code

Function exit_code 

Source
pub fn exit_code(outcome: ChildOutcome) -> i32
Expand description

What: Translate a child’s end into this process’s exit code. Why: Git 2.56.0 run-command.c reports a child killed by signal N as 128 + N, which is also what a POSIX shell reports; an exit code passes through.

In TS you’d write (pseudocode):

function exitCode(outcome: ChildOutcome): number;