pub struct Tool { /* private fields */ }Expand description
Builder for running companion tools.
Implementations§
Source§impl Tool
impl Tool
Sourcepub fn new_process_group(self) -> Self
pub fn new_process_group(self) -> Self
Spawn the subprocess in a new process group so it survives a SIGTERM
sent to the parent’s process group. Use this for cleanup subprocesses
(e.g. bus claims release) that are spawned from a signal handler.
On non-Unix platforms this is a no-op (the flag is ignored).
Sourcepub fn in_workspace(self, workspace: &str) -> Result<Self>
pub fn in_workspace(self, workspace: &str) -> Result<Self>
Wrap this command with maw exec <workspace> --.
Validates that the workspace name matches [a-z0-9][a-z0-9-]* to prevent
argument confusion with the maw CLI.
Auto Trait Implementations§
impl Freeze for Tool
impl RefUnwindSafe for Tool
impl Send for Tool
impl Sync for Tool
impl Unpin for Tool
impl UnsafeUnpin for Tool
impl UnwindSafe for Tool
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