Prune backup after adding new filter(s)

Imagine a scenario where a dir full of log files got backed up and then a filter for *.log or logs/* got added.

Is it possible to then tell duplicacy to run the next backup and prune out filtered files/dirs? Because by default, the backup will run, ignore backing up the log files, but upon restore, they’ll still be there from previous backups. I know I can use the restore filter (but I’d have to pass it on the command line for some reason instead of pointing to the same filters file), but what if I actually wanted those files and only those files deleted from the remote?


No. Snapshots are immutable and pruning works by removing snapshots, not files. So if you want those files gone, you’re going to have to find the snapshots which include them and prune them manually. Or leave them be until they’re pruned naturally by the retention period.

At first look, it might seem useful to restore against a filter file, but if your filters are set properly from the outset, this will do nothing for you. Usually, you do full restores from the latest snapshot revision, where the files are already filtered out. Restores from older revisions tend to be more specific.


Hmm, that’s a bummer. IMO it’d be really good if ignores were treated as deletes so that newer backups after filters are updated are accordingly adjusted.