Sha256: 4d5cd4fc62a58b4dde4328b88bb04eee2b59870d5078bec808b013dbabcdd733

Contents?: true

Size: 556 Bytes

Versions: 22

Compression:

Stored size: 556 Bytes

Contents

class Specinfra::Command::Redhat::Base::Package < Specinfra::Command::Linux::Base::Package
  class << self
    def check_is_installed(package, version=nil)
      cmd = "rpm -q #{escape(package)}"
      if version
        cmd = "#{cmd} | grep -w -- #{escape(version)}"
      end
      cmd
    end

    alias :check_is_installed_by_rpm :check_is_installed

    def get_version(package, opts=nil)
      "rpm -qi #{package} | grep Version | awk '{print $3}'"
    end

    def install(package)
      cmd = "yum -y install #{package}"
    end
  end
end









Version data entries

22 entries across 22 versions & 1 rubygems

Version Path
specinfra-2.0.0.beta37 lib/specinfra/command/redhat/base/package.rb
specinfra-2.0.0.beta36 lib/specinfra/command/redhat/base/package.rb
specinfra-2.0.0.beta35 lib/specinfra/command/redhat/base/package.rb
specinfra-2.0.0.beta34 lib/specinfra/command/redhat/base/package.rb
specinfra-2.0.0.beta33 lib/specinfra/command/redhat/base/package.rb
specinfra-2.0.0.beta32 lib/specinfra/command/redhat/base/package.rb
specinfra-2.0.0.beta31 lib/specinfra/command/redhat/base/package.rb
specinfra-2.0.0.beta30 lib/specinfra/command/redhat/base/package.rb
specinfra-2.0.0.beta29 lib/specinfra/command/redhat/base/package.rb
specinfra-2.0.0.beta28 lib/specinfra/command/redhat/base/package.rb
specinfra-2.0.0.beta27 lib/specinfra/command/redhat/base/package.rb
specinfra-2.0.0.beta26 lib/specinfra/command/redhat/base/package.rb
specinfra-2.0.0.beta25 lib/specinfra/command/redhat/base/package.rb
specinfra-2.0.0.beta24 lib/specinfra/command/redhat/base/package.rb
specinfra-2.0.0.beta23 lib/specinfra/command/redhat/base/package.rb
specinfra-2.0.0.beta22 lib/specinfra/command/redhat/base/package.rb
specinfra-2.0.0.beta21 lib/specinfra/command/redhat/base/package.rb
specinfra-2.0.0.beta20 lib/specinfra/command/redhat/base/package.rb
specinfra-2.0.0.beta19 lib/specinfra/command/redhat/base/package.rb
specinfra-2.0.0.beta18 lib/specinfra/command/redhat/base/package.rb