Sha256: 867ac8c50ad70ee2e9b7bba2a5d41701155dbb7ac25049c72d576762cf40d70d

Contents?: true

Size: 450 Bytes

Versions: 16

Compression:

Stored size: 450 Bytes

Contents

plugins = [] # a list of all plugins
Dir.glob(File.join(MACK_PLUGINS, "*")).each do |d|
  plugins << d
  $: << File.join(d, "lib") # add the lib for this plugin to the global load path
end
plugins.sort.each do |plug|
  begin
    require File.join(plug, "init.rb") # load the init.rb for each plugin.
  rescue Exception => e
    puts e.message
  end
  $:.delete(File.join(plug, "lib")) # remove the plugins lib directory from the global load path.
end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
mack-0.0.6.1 initialization/initializers/plugins.rb
mack-0.0.6.2 initialization/initializers/plugins.rb
mack-0.0.6 initialization/initializers/plugins.rb
mack-0.2.0.1 lib/initialization/initializers/plugins.rb
mack-0.2.0 lib/initialization/initializers/plugins.rb
mack-0.0.7.0 lib/initialization/initializers/plugins.rb
mack-0.1.0 lib/initialization/initializers/plugins.rb
mack-0.4.2.1 lib/initialization/initializers/plugins.rb
mack-0.3.0 lib/initialization/initializers/plugins.rb
mack-0.4.0 lib/initialization/initializers/plugins.rb
mack-0.4.0.1 lib/initialization/initializers/plugins.rb
mack-0.4.1 lib/initialization/initializers/plugins.rb
mack-0.4.5 lib/initialization/initializers/plugins.rb
mack-0.4.7 lib/initialization/initializers/plugins.rb
mack-0.4.2 lib/initialization/initializers/plugins.rb
mack-0.4.6 lib/initialization/initializers/plugins.rb