mercurial/progress.py
changeset 25581 79c75459321e
parent 25497 93b8b0049932
child 25847 56674fd6dabc
equal deleted inserted replaced
25580:a69983942fb4 25581:79c75459321e
    15 
    15 
    16 def spacejoin(*args):
    16 def spacejoin(*args):
    17     return ' '.join(s for s in args if s)
    17     return ' '.join(s for s in args if s)
    18 
    18 
    19 def shouldprint(ui):
    19 def shouldprint(ui):
    20     return not ui.plain() and (ui._isatty(sys.stderr) or
    20     return not (ui.quiet or ui.plain()) and (
    21                                ui.configbool('progress', 'assume-tty'))
    21         ui._isatty(sys.stderr) or ui.configbool('progress', 'assume-tty'))
    22 
    22 
    23 def fmtremaining(seconds):
    23 def fmtremaining(seconds):
    24     """format a number of remaining seconds in humain readable way
    24     """format a number of remaining seconds in humain readable way
    25 
    25 
    26     This will properly display seconds, minutes, hours, days if needed"""
    26     This will properly display seconds, minutes, hours, days if needed"""
   247                     if self._oktoprint(now):
   247                     if self._oktoprint(now):
   248                         self.lastprint = now
   248                         self.lastprint = now
   249                         self.show(now, topic, *self.topicstates[topic])
   249                         self.show(now, topic, *self.topicstates[topic])
   250         finally:
   250         finally:
   251             self._refreshlock.release()
   251             self._refreshlock.release()
   252