Skip to main content

CommandExt

Trait CommandExt 

Source
pub trait CommandExt {
    // Required method
    fn output_err(self, print_logs: bool) -> Result<Output>;
}
Expand description

Extension trait for Command that helps to wrap output and print logs from command execution.

Command

Required Methods§

Source

fn output_err(self, print_logs: bool) -> Result<Output>

Executes the command as a child process, then captures an output and return it. If command termination wasn’t successful wraps an output into error and return it

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl CommandExt for Command

Source§

fn output_err(self, print_logs: bool) -> Result<Output>

Implementors§