Sha256: 8189b519e110c2dab480dd93f4f667e0fd9a162d08907311996942d81682ac58

Contents?: true

Size: 445 Bytes

Versions: 1

Compression:

Stored size: 445 Bytes

Contents

module Brewdler
  class BrewInstaller
    def self.install(name, options = {})
      if `which brew`; $?.success?
        command = "brew install #{name}"
        unless options[:args].nil?
          options[:args].each do |arg|
            command << " --#{arg}"
          end
        end

        `#{command}`
      else
        raise "Unable to install #{name}. Homebrew is not currently installed on your system"
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
brewdler-1.1.1 lib/brewdler/brew_installer.rb