lib/tty/command/printers/abstract.rb in tty-command-0.2.0 vs lib/tty/command/printers/abstract.rb in tty-command-0.3.0
- old
+ new
@@ -19,27 +19,27 @@
#
# @api public
def initialize(output, options = {})
@output = output
@options = options
- enabled = options.fetch(:color) { true }
- @color = ::Pastel.new(output: output, enabled: enabled)
+ @enabled = options.fetch(:color) { true }
+ @color = ::Pastel.new(output: output, enabled: @enabled)
end
def print_command_start(cmd, *args)
write(cmd.to_command + "#{args.join}")
end
def print_command_out_data(cmd, *args)
- write(args.join)
+ write(args.join(' '))
end
def print_command_err_data(cmd, *args)
- write(args.join)
+ write(args.join(' '))
end
def print_command_exit(cmd, *args)
- write(args.join)
+ write(args.join(' '))
end
def write(message)
raise NotImplemented, "Abstract printer cannot be used"
end