pub fn rotate_files(
dir: &Path,
config: &RetentionConfig,
dry_run: bool,
trash_cmd: Option<&str>,
) -> Result<(usize, usize)>Expand description
Rotates files in a directory based on retention policies.
ยงErrors
Returns an error if:
keep_lastis 0 (must be at least 1)- The directory cannot be read
- Files cannot be moved to trash