Add a yellow block method for logging warnings in yellow.

This commit is contained in:
Chris Eppstein 2011-04-16 00:16:37 -07:00
parent 8a8d625a7d
commit 7db7e019ab

View File

@ -48,6 +48,15 @@ module Compass
$stdout.write(color(:clear))
end
def yellow
$stderr.write(color(:yellow))
$stdout.write(color(:yellow))
yield
ensure
$stderr.write(color(:clear))
$stdout.write(color(:clear))
end
def color(c)
if Compass.configuration.color_output && c && COLORS.has_key?(c.to_sym)
if defined?($boring) && $boring