diff --git a/borgmatic/borg/transfer.py b/borgmatic/borg/transfer.py index 5e16efce..7b168035 100644 --- a/borgmatic/borg/transfer.py +++ b/borgmatic/borg/transfer.py @@ -32,11 +32,18 @@ def transfer_archives( + flags.make_flags('remote-path', remote_path) + flags.make_flags('umask', config.get('umask')) + flags.make_flags('log-json', global_arguments.log_json) - + flags.make_flags('lock-wait', config.get('lock_wait', None)) + + flags.make_flags('lock-wait', config.get('lock_wait')) + + flags.make_flags('progress', config.get('progress')) + ( flags.make_flags_from_arguments( transfer_arguments, - excludes=('repository', 'source_repository', 'archive', 'match_archives'), + excludes=( + 'repository', + 'source_repository', + 'archive', + 'match_archives', + 'progress', + ), ) or ( flags.make_match_archives_flags( diff --git a/tests/unit/borg/test_transfer.py b/tests/unit/borg/test_transfer.py index ced41f3c..b2b9886d 100644 --- a/tests/unit/borg/test_transfer.py +++ b/tests/unit/borg/test_transfer.py @@ -440,8 +440,11 @@ def test_transfer_archives_with_progress_calls_borg_with_progress_flags(): flexmock(module.borgmatic.logger).should_receive('add_custom_log_levels') flexmock(module.logging).ANSWER = module.borgmatic.logger.ANSWER flexmock(module.flags).should_receive('make_flags').and_return(()) + flexmock(module.flags).should_receive('make_flags').with_args('progress', True).and_return( + ('--progress',) + ) flexmock(module.flags).should_receive('make_match_archives_flags').and_return(()) - flexmock(module.flags).should_receive('make_flags_from_arguments').and_return(('--progress',)) + flexmock(module.flags).should_receive('make_flags_from_arguments').and_return(()) flexmock(module.flags).should_receive('make_repository_flags').and_return(('--repo', 'repo')) flexmock(module.environment).should_receive('make_environment') flexmock(module.borgmatic.config.paths).should_receive('get_working_directory').and_return(None)