class Pathname
def cookbook?
-
(Boolean)
-
def cookbook? join("metadata.json").exist? || join("metadata.rb").exist? end
def cookbook_root
-
(Pathname, nil)
-
def cookbook_root ascend do |potential_root| if potential_root.cookbook? return potential_root end end end