Method: CommandKit::Colors::ANSI.black

Defined in:
lib/command_kit/colors.rb

.black(string = nil) ⇒ String, BLACK

Sets the text color to black.

Parameters:

  • string (String, nil) (defaults to: nil)

    An optional string.

Returns:

  • (String, BLACK)

    The colorized string or just BLACK if no arguments were given.

See Also:



138
139
140
141
142
# File 'lib/command_kit/colors.rb', line 138

def black(string=nil)
  if string then "#{BLACK}#{string}#{RESET_COLOR}"
  else           BLACK
  end
end