summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/bb/ui
diff options
context:
space:
mode:
Diffstat (limited to 'bitbake/lib/bb/ui')
-rw-r--r--bitbake/lib/bb/ui/knotty.py19
1 files changed, 14 insertions, 5 deletions
diff --git a/bitbake/lib/bb/ui/knotty.py b/bitbake/lib/bb/ui/knotty.py
index a520895da2..52e6eb96fe 100644
--- a/bitbake/lib/bb/ui/knotty.py
+++ b/bitbake/lib/bb/ui/knotty.py
@@ -278,22 +278,31 @@ class TerminalFilter(object):
278 content += ':' 278 content += ':'
279 print(content) 279 print(content)
280 else: 280 else:
281 scene_tasks = "%s of %s" % (self.helper.setscene_current, self.helper.setscene_total)
282 cur_tasks = "%s of %s" % (self.helper.tasknumber_current, self.helper.tasknumber_total)
283
284 content = ''
285 if not self.quiet:
286 msg = "Setscene tasks: %s" % scene_tasks
287 content += msg + "\n"
288 print(msg)
289
281 if self.quiet: 290 if self.quiet:
282 content = "Running tasks (%s of %s, %s of %s)" % (self.helper.setscene_current, self.helper.setscene_total, self.helper.tasknumber_current, self.helper.tasknumber_total) 291 msg = "Running tasks (%s, %s)" % (scene_tasks, cur_tasks)
283 elif not len(activetasks): 292 elif not len(activetasks):
284 content = "Setscene tasks: %s of %s\nNo currently running tasks (%s of %s)" % (self.helper.setscene_current, self.helper.setscene_total, self.helper.tasknumber_current, self.helper.tasknumber_total) 293 msg = "No currently running tasks (%s)" % cur_tasks
285 else: 294 else:
286 content = "Setscene tasks: %s of %s\nCurrently %2s running tasks (%s of %s)" % (self.helper.setscene_current, self.helper.setscene_total, len(activetasks), self.helper.tasknumber_current, self.helper.tasknumber_total) 295 msg = "Currently %2s running tasks (%s)" % (len(activetasks), cur_tasks)
287 maxtask = self.helper.tasknumber_total 296 maxtask = self.helper.tasknumber_total
288 if not self.main_progress or self.main_progress.maxval != maxtask: 297 if not self.main_progress or self.main_progress.maxval != maxtask:
289 widgets = [' ', progressbar.Percentage(), ' ', progressbar.Bar()] 298 widgets = [' ', progressbar.Percentage(), ' ', progressbar.Bar()]
290 self.main_progress = BBProgress("Running tasks", maxtask, widgets=widgets, resize_handler=self.sigwinch_handle) 299 self.main_progress = BBProgress("Running tasks", maxtask, widgets=widgets, resize_handler=self.sigwinch_handle)
291 self.main_progress.start(False) 300 self.main_progress.start(False)
292 self.main_progress.setmessage(content) 301 self.main_progress.setmessage(msg)
293 progress = self.helper.tasknumber_current - 1 302 progress = self.helper.tasknumber_current - 1
294 if progress < 0: 303 if progress < 0:
295 progress = 0 304 progress = 0
296 content = self.main_progress.update(progress) 305 content += self.main_progress.update(progress)
297 print('') 306 print('')
298 lines = self.getlines(content) 307 lines = self.getlines(content)
299 if self.quiet == 0: 308 if self.quiet == 0: