Module: EverydayPlugins::Loader
- Defined in:
- lib/everyday-plugins/plugin.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.depend(*deps, &block) ⇒ Object
94 95 96 97 98 99 100 |
# File 'lib/everyday-plugins/plugin.rb', line 94 def self.depend(*deps, &block) met = deps.all? { |dep| matches = Gem::Specification.find_all_by_name(*dep) !(matches.nil? || matches.empty?) } block.call if met end |
Instance Method Details
#depend(*deps, &block) ⇒ Object
90 91 92 |
# File 'lib/everyday-plugins/plugin.rb', line 90 def depend(*deps, &block) EverydayPlugins::Loader.depend(*deps, &block) end |