From 6b09ca80222954639c6a41ed0bdcc86c1f42ce4e Mon Sep 17 00:00:00 2001 From: Divyansh Singh Date: Tue, 1 Aug 2023 01:51:37 +0530 Subject: [PATCH] exclude configs too and not just the manifest --- borgmatic/actions/create.py | 4 +++- borgmatic/borg/create.py | 6 +++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/borgmatic/actions/create.py b/borgmatic/actions/create.py index 2fa7978..7a6b935 100644 --- a/borgmatic/actions/create.py +++ b/borgmatic/actions/create.py @@ -92,7 +92,9 @@ def run_create( global_arguments.dry_run, ) if config.get('store_config_files', True): - create_borgmatic_manifest(config, global_arguments.used_config_paths, global_arguments.dry_run) + create_borgmatic_manifest( + config, global_arguments.used_config_paths, global_arguments.dry_run + ) stream_processes = [process for processes in active_dumps.values() for process in processes] json_output = borgmatic.borg.create.create_archive( diff --git a/borgmatic/borg/create.py b/borgmatic/borg/create.py index d778e56..db94e2f 100644 --- a/borgmatic/borg/create.py +++ b/borgmatic/borg/create.py @@ -354,7 +354,11 @@ def create_archive( expand_directories( tuple(config.get('source_directories', ())) + borgmatic_source_directories - + tuple(global_arguments.used_config_paths) + + tuple( + global_arguments.used_config_paths + if config.get('store_config_files', True) + else () + ) ) ), additional_directory_devices=map_directories_to_devices(