pub struct CommandBuilder { /* private fields */ }
Expand description
Builder for creating commands
Implementations§
Source§impl CommandBuilder
impl CommandBuilder
pub fn new(id: impl Into<String>, command: impl Into<String>) -> Self
pub fn label(self, label: impl Into<String>) -> Self
pub fn description(self, description: impl Into<String>) -> Self
pub fn args(self, args: Vec<String>) -> Self
pub fn arg(self, arg: impl Into<String>) -> Self
pub fn env(self, key: impl Into<String>, value: impl Into<String>) -> Self
pub fn cwd(self, cwd: impl Into<PathBuf>) -> Self
pub fn category(self, category: CommandCategory) -> Self
pub fn priority(self, priority: u8) -> Self
pub fn condition(self, condition: Condition) -> Self
pub fn tag(self, tag: impl Into<String>) -> Self
pub fn requires_input(self, requires_input: bool) -> Self
pub fn estimated_duration(self, seconds: u32) -> Self
pub fn build(self) -> Command
Auto Trait Implementations§
impl Freeze for CommandBuilder
impl RefUnwindSafe for CommandBuilder
impl Send for CommandBuilder
impl Sync for CommandBuilder
impl Unpin for CommandBuilder
impl UnwindSafe for CommandBuilder
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