Crate ytil_cmd

Crate ytil_cmd 

Source
Expand description

Execute system commands with structured errors and optional silenced output in release builds.

Exposes an extension trait CmdExt with an exec method plus a helper silent_cmd that null-routes stdout/stderr outside debug mode. Errors capture the command name, args and working directory for concise diagnostics.

See CmdError for failure variants with rich context.

Structs§

Cmd
Snapshot of command name, args and cwd.

Enums§

CmdError
Command execution errors with contextual details.

Traits§

CmdExt
Extension trait for Command to execute and handle errors.

Functions§

extract_success_output
Extracts and validates successful command output, converting it to a trimmed string.
silent_cmd
Creates a Command for program; silences stdout/stderr in release builds.
to_ut8_string 🔒