lib/autobuild/reporting.rb in autobuild-1.6.0.b2 vs lib/autobuild/reporting.rb in autobuild-1.6.0.b3

- old
+ new

@@ -14,19 +14,19 @@ require 'autobuild/config' require 'autobuild/exceptions' module Autobuild def self.message(*args) - if !progress_messages.empty? + if @last_progress_msg puts + @last_progress_msg = nil end if args.empty? puts else puts "#{color(*args)}" end - @last_msg = nil end class << self attr_reader :progress_messages end @@ -83,14 +83,14 @@ found end def self.display_progress msg = "#{progress_messages.map(&:last).join(" | ")}" - if @last_msg && @last_msg.length > msg.length - print "\r" + " " * @last_msg.length + if @last_progress_msg && @last_progress_msg.length > msg.length + print "\r" + " " * @last_progress_msg.length end print "\r #{msg}" - @last_msg = msg + @last_progress_msg = msg end # The exception type that is used to report multiple errors that occured # when ignore_errors is set class CompositeException < Autobuild::Exception