Class: Discharger::SetupRunner::Commands::BrewCommand

Inherits:
BaseCommand
  • Object
show all
Defined in:
lib/discharger/setup_runner/commands/brew_command.rb

Constant Summary collapse

RETRY_DELAY_SECONDS =
2

Instance Attribute Summary

Attributes inherited from BaseCommand

#app_root, #config, #logger

Instance Method Summary collapse

Methods inherited from BaseCommand

#initialize

Constructor Details

This class inherits a constructor from Discharger::SetupRunner::Commands::BaseCommand

Instance Method Details

#can_execute?Boolean

Returns:

  • (Boolean)


18
19
20
# File 'lib/discharger/setup_runner/commands/brew_command.rb', line 18

def can_execute?
  File.exist?("Brewfile")
end

#descriptionObject



22
23
24
# File 'lib/discharger/setup_runner/commands/brew_command.rb', line 22

def description
  "Install Homebrew dependencies"
end

#executeObject



11
12
13
14
15
16
# File 'lib/discharger/setup_runner/commands/brew_command.rb', line 11

def execute
  proceed_with "brew bundle" do
    log "Ensuring brew dependencies"
    run_brew_bundle
  end
end