Sha256: bd48a7965c351e7481c27876399569bca86599248b64ccb811f096d2b89cdac9
Contents?: true
Size: 1.63 KB
Versions: 44
Compression:
Stored size: 1.63 KB
Contents
# --- AUTO-INCLUDE STANDARD MU COOKBOOKS --- # # --- DO NOT DELETE THESE COMMENTS UNLESS YOU HAVE A PLAN --- # addtl_cookbooks = {} if ENV.include? "MU_COOKBOOK_ROOT" cookbookPath = "#{ENV['MU_COOKBOOK_ROOT']}/cookbooks" siteCookbookPath = "#{ENV['MU_COOKBOOK_ROOT']}/site_cookbooks" if ENV.include? "MU_DEPRESOLVE" ["cookbooks", "site_cookbooks"].each { |dir| next if !Dir.exists?(ENV['MU_COOKBOOK_ROOT']+"/"+dir) Dir.foreach(ENV['MU_COOKBOOK_ROOT']+"/"+dir).each { |cb| next if cb == "." or cb == ".." path = ENV['MU_COOKBOOK_ROOT']+"/"+dir+"/"+cb next if !File.exists?(path+"/metadata.rb") and !File.exists?(path+"/metadata.json") addtl_cookbooks[cb] = { "path" => path } } } # now to smoke some rocks if File.exists?("#{ENV['MU_COOKBOOK_ROOT']}/Berksfile.lock") in_deps = false File.open("#{ENV['MU_COOKBOOK_ROOT']}/Berksfile.lock").each { |line| if in_deps if line.match(/^ ([^\s]+)\s+\((.*?)\)/) cb = Regexp.last_match[1] vers = Regexp.last_match[2] if vers addtl_cookbooks[cb] ||= {} addtl_cookbooks[cb]["version"] = vers end elsif line.match(/^\s*$/) break end end in_deps = true if line.match(/^DEPENDENCIES$/) } end end end source "https://supermarket.getchef.com" addtl_cookbooks.each_pair { |cb, cfg| if cfg.has_key?("version") and cfg.has_key?("path") cookbook cb, cfg["version"], path: cfg["path"] elsif cfg.has_key?("version") cookbook cb, cfg["version"] else cookbook cb, path: cfg["path"] end }
Version data entries
44 entries across 44 versions & 1 rubygems