diff --git a/progress/__init__.py b/progress/__init__.py index be90a43..f48a625 100644 --- a/progress/__init__.py +++ b/progress/__init__.py @@ -101,9 +101,10 @@ def writeln(self, line): print('\r' + line, end='', file=self.file) self.file.flush() - def finish(self): + def finish(self, print_newline=True): if self.file and self.is_tty(): - print(file=self.file) + if print_newline: + print(file=self.file) if self._hidden_cursor: print(SHOW_CURSOR, end='', file=self.file) self._hidden_cursor = False