Module: Kimurai

Defined in:
lib/kimurai.rb,
lib/kimurai/cli.rb,
lib/kimurai/base.rb,
lib/kimurai/runner.rb,
lib/kimurai/version.rb,
lib/kimurai/pipeline.rb,
lib/kimurai/base/saver.rb,
lib/kimurai/base_helper.rb,
lib/kimurai/base/storage.rb,
lib/kimurai/cli/generator.rb,
lib/kimurai/browser_builder.rb,
lib/kimurai/cli/ansible_command_builder.rb

Defined Under Namespace

Modules: BaseHelper, BrowserBuilder Classes: Base, CLI, Pipeline, Runner

Constant Summary collapse

VERSION =
"1.4.0"

Class Method Summary collapse

Class Method Details

.configurationObject


22
23
24
# File 'lib/kimurai.rb', line 22

def configuration
  @configuration ||= OpenStruct.new
end

.configure {|configuration| ... } ⇒ Object

Yields:


26
27
28
# File 'lib/kimurai.rb', line 26

def configure
  yield(configuration)
end

.envObject


30
31
32
# File 'lib/kimurai.rb', line 30

def env
  ENV.fetch("KIMURAI_ENV") { "development" }
end

.find_by_name(name) ⇒ Object


49
50
51
52
# File 'lib/kimurai.rb', line 49

def find_by_name(name)
  return unless name
  Base.descendants.find { |klass| klass.name == name }
end

.listObject


42
43
44
45
46
47
# File 'lib/kimurai.rb', line 42

def list
  Base.descendants.map do |klass|
    next unless klass.name
    [klass.name, klass]
  end.compact.to_h
end

.time_zoneObject


34
35
36
# File 'lib/kimurai.rb', line 34

def time_zone
  ENV["TZ"]
end

.time_zone=(value) ⇒ Object


38
39
40
# File 'lib/kimurai.rb', line 38

def time_zone=(value)
  ENV.store("TZ", value)
end