put an entire line of output inside a single mutex so we don't cross the streams

This commit is contained in:
David Dollar
2012-01-29 00:09:44 -05:00
parent 2705520496
commit 2490dd2a5b

View File

@@ -124,11 +124,12 @@ private ######################################################################
end
def info(message, name="system", color=Term::ANSIColor.white)
print color
print "#{Time.now.strftime("%H:%M:%S")} #{pad_process_name(name)} | "
print Term::ANSIColor.reset
print message.chomp
puts ""
output = ""
output += color
output += "#{Time.now.strftime("%H:%M:%S")} #{pad_process_name(name)} | "
output += Term::ANSIColor.reset
output += message.chomp
puts output
end
def print(message=nil)