Sha256: 460e7c10ff81dca7556e35433eca6b7442326a8a6bda79d7a650e8d305be881d

Contents?: true

Size: 730 Bytes

Versions: 4

Compression:

Stored size: 730 Bytes

Contents

class ChefCapConfiguration
  class << self
    attr_accessor :configuration

    def set_repository_settings
      repository_value = @configuration.send(:repository) rescue false
      case repository_value
        when /git/
          @configuration.send(:set, :scm, :git)
          @configuration.send(:set, :git_enable_submodules, 1)
          @configuration.send(:default_run_options)[:pty] = true
          @configuration.send(:depend, :remote, :command, "git")
        when /svn/
          @configuration.send(:set, :scm, :svn)
          @configuration.send(:depend, :remote, :command, "svn")
      end
      @configuration.send(:set, :revision, ChefCapHelper.set_revision) if ChefCapHelper.has_revision?
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
chef_cap-0.3.1 recipes/lib/chef_cap_configuration.rb
chef_cap-0.3.0 recipes/lib/chef_cap_configuration.rb
chef_cap-0.2.9 recipes/lib/chef_cap_configuration.rb
chef_cap-0.2.8 recipes/lib/chef_cap_configuration.rb