lib/fasten/ui/curses.rb in fasten-0.14.2 vs lib/fasten/ui/curses.rb in fasten-0.14.4

- old
+ new

@@ -37,11 +37,11 @@ self.clear_needed = false end def draw_title ui_text_aligned(0, :left, 'Fasten your seatbelts!') - ui_text_aligned(0, :center, name.to_s) + ui_text_aligned(0, :center, "#{name} #{$PID}") ui_text_aligned(0, :right, Time.new.to_s) end def cleanup close_screen @@ -125,14 +125,15 @@ force_clear end def ui_jobs_summary - running_count = tasks.running.count - waiting_count = tasks.waiting.count - workers_count = workers.count + running = tasks.running.count + waiting = tasks.waiting.count + working = workers.count + idle = working - running - "Procs running: #{running_count} idle: #{workers_count - running_count} waiting: #{waiting_count} #{runner.use_threads ? 'threads' : 'processes'}: #{jobs}" + "Procs running: #{running} idle: #{idle} waiting: #{waiting} #{runner.use_threads ? 'threads' : 'processes'}: #{jobs}" end def ui_jobs l = ui_text_aligned(1, :left, ui_jobs_summary) + 1