pub struct WalkOptions {
pub ignore_filename: Option<String>,
pub include_dirs: bool,
}Expand description
What’s the ignore file name and should we add directories to the result?
Fields§
§ignore_filename: Option<String>The ignore filename (.gitignore, .xvcignore, .ignore, etc.) or None for not
ignoring anything.
include_dirs: boolShould the results include directories themselves? Note that they are always traversed, but may not be listed if we’re only interested in actual files.
Implementations§
Source§impl WalkOptions
impl WalkOptions
Sourcepub fn gitignore() -> Self
pub fn gitignore() -> Self
Instantiate a Git repository walker that uses .gitignore as ignore file name and includes
directories in results.
Sourcepub fn xvcignore() -> Self
pub fn xvcignore() -> Self
Instantiate a Xvc repository walker that uses .xvcignore as ignore file name and includes
directories in results.
Sourcepub fn without_dirs(self) -> Self
pub fn without_dirs(self) -> Self
Return options with include_dirs turned off.
WalkOptions::xvcignore().without_dirs() specifies a xvcignore walker that only lists
files.
Trait Implementations§
Source§impl Clone for WalkOptions
impl Clone for WalkOptions
Source§fn clone(&self) -> WalkOptions
fn clone(&self) -> WalkOptions
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for WalkOptions
impl RefUnwindSafe for WalkOptions
impl Send for WalkOptions
impl Sync for WalkOptions
impl Unpin for WalkOptions
impl UnwindSafe for WalkOptions
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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