Make it possible to include a file in the filters file

Hi there,

I was using CrashPlan too and I have converted my repositories to a common duplicacy storage.
To support different backup schedules, I do backup some folders in the user profile using an own snapshot-id, and so I have several snapshots per machine. All snapshots have some different filters and a common filter base set.
I use the preference nobackup_file to exclude these folders in the backup of the user profile.

In my fork at github, I have extended the filter file syntax with a new statement to include another filter file.
Using @<filename>, you can now include other files. Relative paths are supported.
In addition I have changed the exclude behavior for the .duplicacy folder. When using nobackup_file, this folder will not get excluded anymore. I use filters that exclude cache and internal files (see this post).

I will make a pull request soon to include this feature :slight_smile:

2 Likes

If I understood your implementation correctly, it may be the last missing feature for a centralized preferences file.

See this topic:

Hi,

at the moment the location of the entry point for the filter file is still fixed to .duplicacy/filters. The location is not configurable in the preferences file.

Indeed you can now keep all configuration in a small tree outside the data and use the include-feature to streamline your filter configuration, instead of duplicating all filters into all repository configurations. But you will still need separate configuration directories to use different filters for different snapshots.

I thought I could use this to point to different filter files. :neutral_face:

But it is undoubtedly an interesting implementation! :clap:

When you have made the PR put the link here.

2 Likes

I know this is possible to define a filters file to filter what will or will not be backup for every repository. But I would like to use one global filter for all my repository, using CLI or the new WEB-UI.
I didn’t see anything on that in the documentation. Is it possible ?

1 Like

This would also be nice if we could use a global filter file as a base to append repository-specific filters to. My use case would be to exclude files and folders that I never want to back up in any repository (e.g., temporary files, Lightroom thumbnails, macOS files and folders like .DS_Store, and many others that I otherwise have to keep up to date for each repo).

A post was split to a new topic: Issues using filters with duplicacy web edition

So is this #planned, @gchen?

1 Like

For anyone else who stumbles across this thread, this feature was implemented in v2.2.0 of the CLI.

4 Likes

This topic was automatically closed after 20 days. New replies are no longer allowed.