Struct dotfiles_actions::create::action::CreateAction
source · pub struct CreateAction<'a, F: FileSystem> { /* private fields */ }
Expand description
CreateAction creates a new directory when executed
Implementations§
source§impl<'a, F: FileSystem> CreateAction<'a, F>
impl<'a, F: FileSystem> CreateAction<'a, F>
sourcepub fn create_parent_dirs(&self) -> &bool
pub fn create_parent_dirs(&self) -> &bool
Force creation of the directory and all its parents if they do not exist already.
Setting create_parent_dirs
to true
is equivalent to
using the -p
flag in mkdir
.
sourcepub fn current_dir(&self) -> &PathBuf
pub fn current_dir(&self) -> &PathBuf
Current directory that will be used to determine relative file locations if necessary. It must match the parent directory of the configuration file that declared this action.
Trait Implementations§
source§impl<F: FileSystem> Action<'_> for CreateAction<'_, F>
impl<F: FileSystem> Action<'_> for CreateAction<'_, F>
source§impl<'a, F: FileSystem> ConditionalAction<'a> for CreateAction<'a, F>
impl<'a, F: FileSystem> ConditionalAction<'a> for CreateAction<'a, F>
source§fn skip_in_ci(&self) -> bool
fn skip_in_ci(&self) -> bool
Whether to skip this action in Continuous Integration environments. Read more
§fn check_conditions_and_execute(&self) -> Result<(), DotfilesError>
fn check_conditions_and_execute(&self) -> Result<(), DotfilesError>
Checks that the conditions allow for executing this action, and if so executes it according to
[execute(&self)]. Read more
source§impl<'a, F: FileSystem> Debug for CreateAction<'a, F>
impl<'a, F: FileSystem> Debug for CreateAction<'a, F>
Auto Trait Implementations§
impl<'a, F> Freeze for CreateAction<'a, F>
impl<'a, F> RefUnwindSafe for CreateAction<'a, F>where
F: RefUnwindSafe,
impl<'a, F> Send for CreateAction<'a, F>where
F: Sync,
impl<'a, F> Sync for CreateAction<'a, F>where
F: Sync,
impl<'a, F> Unpin for CreateAction<'a, F>
impl<'a, F> UnwindSafe for CreateAction<'a, F>where
F: RefUnwindSafe,
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