Skip to main content

check

Function check 

Source
pub async fn check<S: TerminalSetup, E: EventSource>(
    workdir: &Path,
    home: Option<&Path>,
    allowed: &[String],
    interactive: bool,
    setup: &mut S,
    events: &mut E,
) -> bool
Expand description

The whole check, for lev run: assess, then ask or warn.

Returns whether the run may proceed. interactive is whether there is a terminal to ask on - when there is not (CI, a pipe, --yolo), the run proceeds with non_interactive_warning on stderr rather than being refused, because refusing would break every unattended caller.