pub fn signal_exit_code(signal: &str) -> i32Expand description
The exit code reported for a process stopped with signal, following the
conventional 128 + signal mapping used by POSIX shells.
use command_stream::signal::signal_exit_code;
assert_eq!(signal_exit_code("SIGINT"), 130); // CTRL+C
assert_eq!(signal_exit_code("SIGTERM"), 143);
assert_eq!(signal_exit_code("SIGKILL"), 137);