pub struct Context {
pub dry_run: bool,
pub debug: bool,
pub verbose: bool,
pub force: bool,
pub root: PathBuf,
pub repository: Repository,
pub overlay: Option<Overlay>,
pub progress: Option<Progress>,
}Fields§
§dry_run: boolRun without applying changes
debug: boolToggle debug traces,
verbose: boolToggle verbose output
force: boolRun overwriting eveything without prompt
root: PathBufTarget root (~)
repository: Repository§overlay: Option<Overlay>§progress: Option<Progress>Implementations§
Source§impl Context
impl Context
pub fn new( dry_run: bool, debug: bool, verbose: bool, force: bool, root: PathBuf, repository: Repository, overlay: Option<Overlay>, ) -> Arc<Self>
pub fn with_overlay(&self, overlay: Overlay) -> Arc<Self>
pub fn with_progress(&self, progress: ProgressBar) -> Arc<Self>
pub fn with_multiprogress(&self, progress: MultiProgress) -> Arc<Self>
pub fn try_progress(&self) -> Option<&ProgressBar>
pub fn try_multiprogress(&self) -> Option<&MultiProgress>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Context
impl RefUnwindSafe for Context
impl Send for Context
impl Sync for Context
impl Unpin for Context
impl UnwindSafe for Context
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