Skip to content

Commit

Permalink
show file count on backup creation
Browse files Browse the repository at this point in the history
  • Loading branch information
Fallen-Breath committed Jun 9, 2024
1 parent 714e8cb commit 07d2791
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions prime_backup/action/create_backup_action.py
Original file line number Diff line number Diff line change
Expand Up @@ -203,6 +203,7 @@ def __scan_files(self) -> _ScanResult:
for scan_target in self.config.backup.targets:
scan_queue.append(Path(scan_target))

self.logger.debug(f'Scanning files at {list(scan_queue)}')
while len(scan_queue) > 0:
scan_target = scan_queue.popleft()
if (target_posix := scan_target.as_posix()) in scanned_targets:
Expand Down Expand Up @@ -509,8 +510,8 @@ def run(self) -> BackupInfo:
targets=scan_result.root_targets,
tags=self.tags.to_dict(),
)
self.logger.info('Creating backup for {} at path {!r}, timestamp {!r}, creator {!r}, comment {!r}, tags {!r}'.format(
scan_result.root_targets, self.__source_path.as_posix(),
self.logger.info('Creating backup for {} at path {!r}, file cnt {}, timestamp {!r}, creator {!r}, comment {!r}, tags {!r}'.format(
scan_result.root_targets, self.__source_path.as_posix(), len(scan_result.all_file_paths),
backup.timestamp, backup.creator, backup.comment, backup.tags,
))

Expand Down

0 comments on commit 07d2791

Please sign in to comment.