Class: Kontena::Cli::LogFormatter::StripColor

Inherits:
Logger::Formatter
  • Object
show all
Defined in:
lib/kontena/cli/log_formatters/strip_color.rb

Instance Method Summary collapse

Instance Method Details

#msg2str(msg) ⇒ Object



7
8
9
# File 'lib/kontena/cli/log_formatters/strip_color.rb', line 7

def msg2str(msg)
  super(msg.kind_of?(String) ? msg.gsub(/\e+\[{1,2}[0-9;:?]+m/m, '') : msg)
end