1
0
Fork 0
mirror of https://github.com/borgbackup/borg.git synced 2024-12-26 01:37:20 +00:00

prune: fix --stats --iec output to use binary units, see #6606

This commit is contained in:
Thomas Waldmann 2022-04-19 21:51:55 +02:00
parent 8d1e012ecc
commit c86d19cc06

View file

@ -1727,8 +1727,8 @@ def do_prune(self, args, repository, manifest, key):
keep += prune_split(archives, rule, num, kept_because) keep += prune_split(archives, rule, num, kept_because)
to_delete = (set(archives) | checkpoints) - (set(keep) | set(keep_checkpoints)) to_delete = (set(archives) | checkpoints) - (set(keep) | set(keep_checkpoints))
stats = Statistics() stats = Statistics(iec=args.iec)
with Cache(repository, key, manifest, lock_wait=self.lock_wait) as cache: with Cache(repository, key, manifest, lock_wait=self.lock_wait, iec=args.iec) as cache:
list_logger = logging.getLogger('borg.output.list') list_logger = logging.getLogger('borg.output.list')
# set up counters for the progress display # set up counters for the progress display
to_delete_len = len(to_delete) to_delete_len = len(to_delete)