浏览代码

fix conflict between --stats and --progress

the --stats output would be slightly garbled by --progress, because of
the \r that is output at the last line...

example:

    initializing cache
    reading files cache
    processing files
    ------------------------------------------------------------------------------ s/twotone
    Archive name: 2015-10-15-test
Antoine Beaupré 9 年之前
父节点
当前提交
7f28244cfe
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      borg/helpers.py

+ 1 - 1
borg/helpers.py

@@ -181,7 +181,7 @@ class Statistics:
                 format_file_size(self.osize), format_file_size(self.csize), format_file_size(self.usize), self.nfiles, path)
         else:
             msg = ' ' * 79
-        print(msg, file=sys.stderr, end='\r')
+        print(msg, file=sys.stderr, end=final and "\n" or "\r")
         sys.stderr.flush()