]> arthur.barton.de Git - bup.git/blobdiff - cmd/fsck-cmd.py
Migrate all xrange calls to range in bup.compat
[bup.git] / cmd / fsck-cmd.py
index 94eeb89f4ae52bb429a725a2d28fb080a59fb581..35b45f8b514a0c07a36d6455bbedc6c85877425c 100755 (executable)
@@ -4,9 +4,12 @@ bup_python="$(dirname "$0")/bup-python" || exit $?
 exec "$bup_python" "$0" ${1+"$@"}
 """
 # end of bup preamble
+
+from __future__ import absolute_import, print_function
 import sys, os, glob, subprocess
+
 from bup import options, git
-from bup.helpers import *
+from bup.helpers import Sha1, chunkyreader, istty2, log, progress
 
 par2_ok = 0
 nullf = open('/dev/null')
@@ -77,7 +80,7 @@ def git_verify(base):
         try:
             quick_verify(base)
         except Exception as e:
-            debug('error: %s\n' % e)
+            log('error: %s\n' % e)
             return 1
         return 0
     else:
@@ -126,7 +129,7 @@ def do_pack(base, last, par2_exists):
         assert(opt.generate and (not par2_ok or par2_exists))
         action_result = 'exists' if par2_exists else 'skipped'
     if opt.verbose:
-        print last, action_result
+        print(last, action_result)
     return code