module InstallGemLocal::InstallGem
Public Instance Methods
install_gem()
click to toggle source
# File lib/install_gem_local/action/install_gem.rb, line 5 def install_gem puts '' puts 'Install Gem'.green files_exists = file_names if files_exists.count > 1 install_gem_from_path(multiple_version_selection(title_interpol: 'TO Install')) elsif files_exists.count == 1 install_gem_from_path(files_exists.first) else ap 'Gem not exist' end end
install_gem_from_path(file_name)
click to toggle source
# File lib/install_gem_local/action/install_gem.rb, line 18 def install_gem_from_path(file_name) return if file_name == 'exit' tty_command.run("gem install #{file_name}") end