Skip to main content

Crate gix_command

Crate gix_command 

Source
Expand description

Launch commands very similarly to Command, but with git specific capabilities and adjustments.

§Examples

let output = gix_command::prepare("git")
    .arg("--version")
    .spawn()?
    .wait_with_output()?;

assert!(output.status.success());
assert!(String::from_utf8(output.stdout)?.starts_with("git version "));

Modules§

shebang

Structs§

Context
Additional information that is relevant to spawned processes, which typically receive a wealth of contextual information when spawned from git.
Prepare
A structure to keep settings to use when invoking a command via spawn(), after creating it with prepare().

Functions§

extract_interpreter
Parse the shebang (#!<path>) from the first line of executable, and return the shebang data when available.
prepare
Prepare cmd for spawning by configuring it with various builder methods.