Skip to content

--exclude-if-present #128

@wavexx

Description

@wavexx

I'm trying to migrate some scripts from rdiff-backup to attic.

One feature which I often used (and seen using a lot) is the ability to exclude directories containing some sort of tag file. Currently attic has --exclude-caches, which checks for CACHEDIR.TAG, but this is rarely used in practice (both for actual caches, and for practical reasons: CACHEDIR.TAG doesn't sort well, which is very helpful for users).

It would be nice to make it general, so that you can exclude directories containing an arbitrary tag file:

attic create --exclude-if-present .NOBACKUP --exclude-if-present 00-NOBACKUP ...

--exclude-caches would basically be a shorthand for --exclude-if-present CACHEDIR.TAG.

It's actually hard to produce an exclusion list with find alone (you at least need to post-process the result), not to mention that this requires a full directory traversal (you cannot use -prune).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions