Class: Shanty::RubygemDiscoverer

Inherits:
Discoverer show all
Defined in:
lib/shanty/discoverers/rubygem.rb

Overview

Public: Discoverer for Shantyfiles will create a a project for every Shantyfile it finds in a directory

Instance Attribute Summary

Attributes inherited from Discoverer

#env

Instance Method Summary collapse

Methods inherited from Discoverer

#discover_all, inherited, #initialize

Constructor Details

This class inherits a constructor from Shanty::Discoverer

Instance Method Details

#discoverObject



9
10
11
12
13
14
15
# File 'lib/shanty/discoverers/rubygem.rb', line 9

def discover
  Dir[File.join(env.root, '**', '*.gemspec')].map do |path|
    create_project_template(File.absolute_path(File.dirname(path))) do |project_template|
      project_template.type = RubygemProject
    end
  end
end