Sha256: f22f7b50d6aa6a928853320d0f6c0f027512aadbbba21b218c8b04995f1aa2f8

Contents?: true

Size: 977 Bytes

Versions: 1

Compression:

Stored size: 977 Bytes

Contents

require 'dep_selector'
require 'zlib'
require 'archive/tar/minitar'
require 'chef/config'
require 'chef/knife/cookbook_site_download'

require 'knife_cookbook_dependencies/version'
require 'knife_cookbook_dependencies/shelf'
require 'knife_cookbook_dependencies/cookbook'
require 'knife_cookbook_dependencies/metacookbook'
require 'knife_cookbook_dependencies/dependency_reader'
require 'knife_cookbook_dependencies/dsl'
require 'knife_cookbook_dependencies/cookbookfile'
require 'knife_cookbook_dependencies/git'

module KnifeCookbookDependencies
  DEFAULT_FILENAME = 'Cookbookfile'
  COOKBOOKS_DIRECTORY = 'cookbooks'

  class << self
    def shelf
      @shelf ||= KnifeCookbookDependencies::Shelf.new
    end

    def clear_shelf!
      @shelf = nil
    end

    def ui=(ui)
      @ui = ui
    end

    def ui
      @ui ||= Chef::Knife::UI.new(STDOUT, STDERR, STDIN, {})
    end

    def clean
      clear_shelf!
      FileUtils.rm_rf COOKBOOKS_DIRECTORY
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
knife_cookbook_dependencies-0.0.1 lib/knife_cookbook_dependencies.rb