X-Git-Url: https://arthur.barton.de/gitweb/?a=blobdiff_plain;f=cmd%2Fsplit-cmd.py;h=500fb194110679e11a184e13ce2acf39057e85b4;hb=c4fdab1acc87dcaf76dc3a973d21d1bfa3643e9c;hp=a23a052d4a0a81833d2b06ceeb5255628beef949;hpb=b094d7c5570cd97d43f4f8b1766c60476da07491;p=bup.git diff --git a/cmd/split-cmd.py b/cmd/split-cmd.py index a23a052..500fb19 100755 --- a/cmd/split-cmd.py +++ b/cmd/split-cmd.py @@ -5,7 +5,7 @@ exec "$bup_python" "$0" ${1+"$@"} """ # end of bup preamble -from __future__ import absolute_import, print_function +from __future__ import absolute_import, division, print_function import os, sys, time from bup import hashsplit, git, options, client @@ -87,9 +87,9 @@ def prog(filenum, nbytes): total_bytes += nbytes if filenum > 0: qprogress('Splitting: file #%d, %d kbytes\r' - % (filenum+1, total_bytes/1024)) + % (filenum+1, total_bytes // 1024)) else: - qprogress('Splitting: %d kbytes\r' % (total_bytes/1024)) + qprogress('Splitting: %d kbytes\r' % (total_bytes // 1024)) is_reverse = os.environ.get('BUP_SERVER_REVERSE') @@ -190,7 +190,7 @@ else: hashsplit.total_split += len(blob) if opt.copy: sys.stdout.write(str(blob)) - megs = hashsplit.total_split/1024/1024 + megs = hashsplit.total_split // 1024 // 1024 if not opt.quiet and last != megs: last = megs @@ -223,7 +223,7 @@ secs = time.time() - start_time size = hashsplit.total_split if opt.bench: log('bup: %.2f kbytes in %.2f secs = %.2f kbytes/sec\n' - % (size/1024., secs, size/1024./secs)) + % (size / 1024, secs, size / 1024 / secs)) if saved_errors: log('WARNING: %d errors encountered while saving.\n' % len(saved_errors))