pub struct TaskArgs {
pub commands: Vec<CommandRunner>,
pub preconditions: Vec<Precondition>,
pub depends_on: Vec<TaskDependency>,
pub labels: HashMap<String, String>,
pub description: String,
pub environment: HashMap<String, String>,
pub env_file: Vec<String>,
pub shell: Option<Shell>,
pub parallel: Option<bool>,
pub ignore_errors: Option<bool>,
pub verbose: Option<bool>,
}
Expand description
This struct represents a task that can be executed. A task can contain multiple commands that are executed sequentially. A task can also have preconditions that must be met before the task can be executed.
Fields§
§commands: Vec<CommandRunner>
The commands to run
preconditions: Vec<Precondition>
The preconditions that must be met before the task can be executed
depends_on: Vec<TaskDependency>
The tasks that must be executed before this task can be executed
labels: HashMap<String, String>
The labels for the task
description: String
The description of the task
environment: HashMap<String, String>
The environment variables to set before running the task
env_file: Vec<String>
The environment files to load before running the task
shell: Option<Shell>
The shell to use when running the task
parallel: Option<bool>
Run the commands in parallel It should only work if the task are local_run commands
ignore_errors: Option<bool>
Ignore errors if the task fails
verbose: Option<bool>
Show verbose output
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for TaskArgs
impl<'de> Deserialize<'de> for TaskArgs
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for TaskArgs
impl RefUnwindSafe for TaskArgs
impl Send for TaskArgs
impl Sync for TaskArgs
impl Unpin for TaskArgs
impl UnwindSafe for TaskArgs
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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more