pub fn run_as_root<S: AsRef<OsStr>>(
argv: &[S],
) -> Result<ExitStatus, EscalationError>Expand description
Run argv as root and return the child’s exit status. Detects whether a
terminal is attached and escalates accordingly. Unlike a sudo exec, this
never replaces the current image — the graphical escalators spawn a fresh
root process, so the caller gets the status back.