Class: I18nliner::Commands::GenericCommand

Inherits:
Object
  • Object
show all
Includes:
BasicFormatter
Defined in:
lib/i18nliner/commands/generic_command.rb

Direct Known Subclasses

Check, Dump, Import

Class Method Summary collapse

Instance Method Summary collapse

Methods included from BasicFormatter

#green, #red

Constructor Details

#initialize(options) ⇒ GenericCommand

Returns a new instance of GenericCommand.


9
10
11
12
13
# File 'lib/i18nliner/commands/generic_command.rb', line 9

def initialize(options)
  @options = options
  @start = Time.now
  extend ColorFormatter if $stdout.tty?
end

Class Method Details

.run(options) ⇒ Object


19
20
21
22
23
# File 'lib/i18nliner/commands/generic_command.rb', line 19

def self.run(options)
  command = new(options)
  command.run
  command
end

Instance Method Details

#success?Boolean

Returns:

  • (Boolean)

15
16
17
# File 'lib/i18nliner/commands/generic_command.rb', line 15

def success?
  true
end