Method: Puppet::Util::Colors#colorize

Defined in:
lib/puppet/util/colors.rb

#colorize(color, str) ⇒ Object



79
80
81
82
83
84
85
86
87
88
# File 'lib/puppet/util/colors.rb', line 79

def colorize(color, str)
  case Puppet[:color]
  when true, :ansi, "ansi", "yes"
      console_color(color, str)
  when :html, "html"
    html_color(color, str)
  else
    str
  end
end