class Gemsmith::CLI::Actions::Install
Handles the install action.
Attributes
Public Class Methods
Source
# File lib/gemsmith/cli/actions/install.rb, line 24 def initialize(installer: Tools::Installer.new, loader: Spek::Loader, **) super(**) @installer = installer @loader = loader end
Calls superclass method
Public Instance Methods
Source
# File lib/gemsmith/cli/actions/install.rb, line 30 def call name = default case installer.call loader.call("#{name}.gemspec") in Success(spec) then logger.info { "Installed: #{spec.package_name}." } in Failure(message) then log_error { message } else log_error { "Unable to handle install action." } end end
Private Instance Methods
Source
# File lib/gemsmith/cli/actions/install.rb, line 42 def log_error(&) = logger.error(&) end