opoo function for warning messages

This commit is contained in:
Max Howell 2009-07-31 03:56:46 +01:00
parent 9b19f194cc
commit a39e0d20c3
2 changed files with 6 additions and 1 deletions

View File

@ -130,7 +130,7 @@ class AbstractFormula
if @md5 and not @md5.empty?
raise "MD5 mismatch: #{md5}" unless md5 == @md5.downcase
else
ohai "Warning: Formula does not provide an MD5 hash."
opoo "Formula does not provide an MD5 hash."
end
# we make an additional subdirectory so know exactly what we are

View File

@ -19,3 +19,8 @@ def ohai title
n=`tput cols`.strip.to_i-4
puts "\033[0;34m==>\033[0;0;1m #{title[0,n]}\033[0;0m"
end
# shows a warning in delicious pink
def opoo warning
puts "WARNING \033[1;35m#{warning}\033[0;0m"
end