Class: FluentCommandBuilder::Printer

Inherits:
Object
  • Object
show all
Includes:
Term::ANSIColor
Defined in:
lib/fluent_command_builder/internal/printer.rb

Instance Method Summary collapse

Instance Method Details



17
18
19
20
# File 'lib/fluent_command_builder/internal/printer.rb', line 17

def print_command(command)
  print magenta, command, reset, "\n"
  $stdout.flush
end


12
13
14
15
# File 'lib/fluent_command_builder/internal/printer.rb', line 12

def print_error(message)
  $stderr.print red, 'Error: ', message, reset, "\n"
  $stderr.flush
end


7
8
9
10
# File 'lib/fluent_command_builder/internal/printer.rb', line 7

def print_warning(message)
  $stderr.print yellow, 'Warning: ', message, reset, "\n"
  $stderr.flush
end