class Billy::Util::UI
Public Class Methods
confirm?( msg = nil )
click to toggle source
# File lib/billy/util/ui.rb, line 21 def confirm?( msg = nil ) inform( msg ) if !msg.nil? input == "y" end
err( msg )
click to toggle source
# File lib/billy/util/ui.rb, line 34 def err( msg ) inform red msg end
green( text )
click to toggle source
# File lib/billy/util/ui.rb, line 13 def green( text ) text.green end
inform( msg )
click to toggle source
# File lib/billy/util/ui.rb, line 26 def inform( msg ) puts "#{msg.to_s}\n" end
input()
click to toggle source
# File lib/billy/util/ui.rb, line 17 def input gets.chomp.downcase end
red( text )
click to toggle source
# File lib/billy/util/ui.rb, line 9 def red( text ) text.red end
succ( msg )
click to toggle source
# File lib/billy/util/ui.rb, line 30 def succ( msg ) inform green msg end