borg
borg copied to clipboard
archive: Store include/exclude instructions in metadata
I was thinking that being able to look up what this archive should actually include could be a helpful feature.
- To find out what actually should be included/excluded in this archive.
- For clients to suggest to inherit the include/exclude from the latest archive while adding a backup to the client.
This would require collecting all the --pattern
, --exclude
, --exclude-from
sources and to be exact also the --keep-exclude-tags
, --exclude-if-present
, --exclude-caches
information and store them for each archive.
@ThomasWaldmann This is very high on my wishlist. Does this need any conceptual considerations for 2.0 or is it rather independent?
- we already store the full commandline
- reading stuff from files can result in a lot of data (could have 1 line per file * millions of files).
- we already store the full commandline
Yes, I'm already extracting some of the information from there. But if a backup is created with an --exclude-from
file argument and the file was in /tmp
that's not helpful.
- reading stuff from files can result in a lot of data (could have 1 line per file * millions of files).
I'm not sure if you maybe misunderstood: I don't want to list all included/excluded files. I only want, for example, to combine the list of --exclude
s and the content of --exclude-file
in the metadata. It would be fine to limit it to 1000 lines and indicate that there was more content.
A patterns file, esp. with "full match" patterns can be simply a list of all files to backup, so it can be huge.
Not sure I want to have a feature that can not always work.