Class: Yoker::Generators::VersionManager::Rbenv

Inherits:
Object
  • Object
show all
Defined in:
lib/yoker/generators/version_manager/rbenv.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(config, shell) ⇒ Rbenv

Returns a new instance of Rbenv.



9
10
11
12
# File 'lib/yoker/generators/version_manager/rbenv.rb', line 9

def initialize(config, shell)
  @config = config
  @shell = shell
end

Instance Attribute Details

#configObject (readonly)

Returns the value of attribute config.



7
8
9
# File 'lib/yoker/generators/version_manager/rbenv.rb', line 7

def config
  @config
end

#shellObject (readonly)

Returns the value of attribute shell.



7
8
9
# File 'lib/yoker/generators/version_manager/rbenv.rb', line 7

def shell
  @shell
end

Instance Method Details

#generateObject



14
15
16
17
18
19
# File 'lib/yoker/generators/version_manager/rbenv.rb', line 14

def generate
  generate_ruby_version_file
  generate_gemrc if needs_gemrc?
  generate_rbenv_vars if needs_env_vars?
  create_rbenv_setup_script
end