pub struct CmdOptions {
pub cwd: Option<PathBuf>,
pub envs: Vec<(String, String)>,
pub env_remove: Vec<String>,
pub stdin: Option<Vec<u8>>,
pub stdin_null: bool,
}Fields§
§cwd: Option<PathBuf>§envs: Vec<(String, String)>§env_remove: Vec<String>§stdin: Option<Vec<u8>>§stdin_null: boolImplementations§
Source§impl CmdOptions
impl CmdOptions
pub fn new() -> Self
pub fn with_envs(self, envs: &[(&str, &str)]) -> Self
pub fn with_env_remove_prefix(self, prefix: &str) -> Self
pub fn with_path_prepend(self, dir: &Path) -> Self
pub fn with_cwd(self, dir: &Path) -> Self
pub fn with_env(self, key: &str, value: &str) -> Self
pub fn with_env_remove(self, key: &str) -> Self
pub fn with_stdin_bytes(self, bytes: &[u8]) -> Self
pub fn with_stdin_str(self, input: &str) -> Self
pub fn inherit_stdin(self) -> Self
Trait Implementations§
Source§impl Clone for CmdOptions
impl Clone for CmdOptions
Source§fn clone(&self) -> CmdOptions
fn clone(&self) -> CmdOptions
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for CmdOptions
impl Debug for CmdOptions
Auto Trait Implementations§
impl Freeze for CmdOptions
impl RefUnwindSafe for CmdOptions
impl Send for CmdOptions
impl Sync for CmdOptions
impl Unpin for CmdOptions
impl UnsafeUnpin for CmdOptions
impl UnwindSafe for CmdOptions
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more