Sha256: f4323a14c5b9fc714555b1a5628ebdac4cbd9b50ed37de3e6d84c4e298610f3d

Contents?: true

Size: 840 Bytes

Versions: 61

Compression:

Stored size: 840 Bytes

Contents

module Sprinkle
  module Installers
    # = RPM Package Installer
    #
    # The RPM package installer installs RPM packages.
    # 
    # == Example Usage
    #
    # Installing the magic_beans RPM. Its all the craze these days.
    #
    #   package :magic_beans do
    #     rpm 'magic_beans'
    #   end
    #
    # You may also specify multiple rpms as an array:
    #
    #   package :magic_beans do
    #     rpm %w(magic_beans magic_sauce)
    #   end
    class Rpm < Installer
      attr_accessor :packages #:nodoc:

      def initialize(parent, packages, &block) #:nodoc:
        super parent, &block
        packages = [packages] unless packages.is_a? Array
        @packages = packages
      end

      protected

        def install_commands #:nodoc:
          "rpm -Uvh #{@packages.join(' ')}"
        end

    end
  end
end

Version data entries

61 entries across 61 versions & 13 rubygems

Version Path
auser-sprinkle-0.1.6 lib/sprinkle/installers/rpm.rb
crafterm-sprinkle-0.1.6 lib/sprinkle/installers/rpm.rb
crafterm-sprinkle-0.1.7 lib/sprinkle/installers/rpm.rb
crafterm-sprinkle-0.1.8 lib/sprinkle/installers/rpm.rb
crafterm-sprinkle-0.1.9 lib/sprinkle/installers/rpm.rb
crafterm-sprinkle-0.2.0 lib/sprinkle/installers/rpm.rb
crafterm-sprinkle-0.2.1 lib/sprinkle/installers/rpm.rb
crafterm-sprinkle-0.2.2 lib/sprinkle/installers/rpm.rb
crafterm-sprinkle-0.2.3 lib/sprinkle/installers/rpm.rb
crafterm-sprinkle-0.2.4 lib/sprinkle/installers/rpm.rb
crafterm-sprinkle-0.2.5 lib/sprinkle/installers/rpm.rb
crafterm-sprinkle-0.2.6 lib/sprinkle/installers/rpm.rb
jemmyw-sprinkle-0.2.3 lib/sprinkle/installers/rpm.rb
jemmyw-sprinkle-0.2.4 lib/sprinkle/installers/rpm.rb
jsierles-sprinkle-0.1.9 lib/sprinkle/installers/rpm.rb
justsee-sprinkle-0.2.4 lib/sprinkle/installers/rpm.rb
lachlan-sprinkle-0.0.1 lib/sprinkle/installers/rpm.rb
lachlan-sprinkle-0.0.10 lib/sprinkle/installers/rpm.rb
lachlan-sprinkle-0.0.11 lib/sprinkle/installers/rpm.rb
lachlan-sprinkle-0.0.13 lib/sprinkle/installers/rpm.rb