Method: Boxen::Check#warn

Defined in:
lib/boxen/check.rb

#warn(message, *extras) ⇒ Object



59
60
61
62
63
64
65
66
67
68
69
70
# File 'lib/boxen/check.rb', line 59

def warn(message, *extras)
  options = Hash === extras.last ? extras.pop : {}
  color   = options[:color] || :yellow

  $stderr.puts ANSI.send(color) { "--> #{message}" }

  unless extras.empty?
    extras.each { |line| $stderr.puts "    #{line}" }
  end

  $stderr.puts
end