pub struct DedupeConfig {Show 13 fields
pub dry_run: bool,
pub output: Option<PathBuf>,
pub modified_before: Option<DateTime<FixedOffset>>,
pub rf_over: Option<usize>,
pub name_patterns: Vec<Pattern>,
pub path_patterns: Vec<Pattern>,
pub priority: Vec<Priority>,
pub keep_name_patterns: Vec<Pattern>,
pub keep_path_patterns: Vec<Pattern>,
pub isolated_roots: Vec<Path>,
pub match_links: bool,
pub no_lock: bool,
pub no_check_size: bool,
}Expand description
Configures which files should be removed
Fields§
§dry_run: boolDon’t perform any changes on the file-system, but writes a log of file operations to the standard output.
output: Option<PathBuf>Write the dry_run report to a file instead of the standard output.
modified_before: Option<DateTime<FixedOffset>>Deduplicate only the files that were modified before the given time.
If any of the files in a group was modified later, the whole group is skipped.
rf_over: Option<usize>Keep at least n replicas untouched.
If not given, it is assumed to be the same as the
--rf-over value in the earlier fclones group run.
name_patterns: Vec<Pattern>Restrict the set of files that can be removed or replaced by links to files with the name matching any given patterns.
path_patterns: Vec<Pattern>Restrict the set of files that can be removed or replaced by links to files with the path matching any given patterns.
priority: Vec<Priority>Set the priority for files to be removed or replaced by links.
keep_name_patterns: Vec<Pattern>Keep files with names matching any given patterns untouched.
keep_path_patterns: Vec<Pattern>Keep files with paths matching any given patterns untouched.
isolated_roots: Vec<Path>Specify a list of path prefixes. If non-empty, all duplicates having the same path prefix (root) are treated as one. This also means that the files sharing the same root can be either all dropped or all retained.
By default, it is set to the input paths given as arguments to the earlier
fclones group command, if --isolate option was present.
match_links: boolTreat files reachable from multiple paths through links as duplicates.
no_lock: boolDon’t lock files before performing an action on them.
no_check_size: boolAllow the size of a file to be different than the size recorded during grouping.
By default, files are checked for size to prevent accidentally removing a file
that was modified since grouping.
However, if --transform was used when grouping, the data sizes recorded in the fclones group
report likely don’t match the on-disk sizes of the files. Therefore,
this flag is set automatically if --transform was used.
Trait Implementations§
Source§impl Args for DedupeConfig
impl Args for DedupeConfig
Source§fn augment_args<'b>(__clap_app: Command) -> Command
fn augment_args<'b>(__clap_app: Command) -> Command
Source§fn augment_args_for_update<'b>(__clap_app: Command) -> Command
fn augment_args_for_update<'b>(__clap_app: Command) -> Command
Command so it can instantiate self via
FromArgMatches::update_from_arg_matches_mut Read moreSource§impl Debug for DedupeConfig
impl Debug for DedupeConfig
Source§impl Default for DedupeConfig
impl Default for DedupeConfig
Source§fn default() -> DedupeConfig
fn default() -> DedupeConfig
Source§impl FromArgMatches for DedupeConfig
impl FromArgMatches for DedupeConfig
Source§fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
Source§fn from_arg_matches_mut(
__clap_arg_matches: &mut ArgMatches,
) -> Result<Self, Error>
fn from_arg_matches_mut( __clap_arg_matches: &mut ArgMatches, ) -> Result<Self, Error>
Source§fn update_from_arg_matches(
&mut self,
__clap_arg_matches: &ArgMatches,
) -> Result<(), Error>
fn update_from_arg_matches( &mut self, __clap_arg_matches: &ArgMatches, ) -> Result<(), Error>
ArgMatches to self.Source§fn update_from_arg_matches_mut(
&mut self,
__clap_arg_matches: &mut ArgMatches,
) -> Result<(), Error>
fn update_from_arg_matches_mut( &mut self, __clap_arg_matches: &mut ArgMatches, ) -> Result<(), Error>
ArgMatches to self.Auto Trait Implementations§
impl Freeze for DedupeConfig
impl RefUnwindSafe for DedupeConfig
impl Send for DedupeConfig
impl Sync for DedupeConfig
impl Unpin for DedupeConfig
impl UnwindSafe for DedupeConfig
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
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>
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>
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