lib/boson.rb in boson-0.2.1 vs lib/boson.rb in boson-0.2.2

- old
+ new

@@ -49,12 +49,17 @@ File.expand_path(e) != repo.dir && !ignored_dirs.include?(File.expand_path('.')) } Repo.new(dir) if dir end end - # The array of loaded repositories containing the main repo and a possible local repo + # The array of loaded repositories containing the main repo and possible local and global repos def repos - @repos ||= [repo, local_repo].compact + @repos ||= [repo, local_repo, global_repo].compact + end + + # Optional global repository at /etc/boson + def global_repo + File.exists?('/etc/boson') ? Repo.new('/etc/boson') : nil end def main_object=(value) #:nodoc: @main_object = value.extend(Universe) end \ No newline at end of file