Module: Lookout::Rake::Tasks
- Defined in:
- lib/lookout/rake/tasks.rb
Defined Under Namespace
Class Method Summary collapse
Class Method Details
.gemspec ⇒ Object
18 19 20 |
# File 'lib/lookout/rake/tasks.rb', line 18 def gemspec @gemspec ||= Dir['%s/*.gemspec' % top_srcdir].first end |
.specification ⇒ Object
22 23 24 25 26 27 |
# File 'lib/lookout/rake/tasks.rb', line 22 def specification return @specification if defined? @specification return nil unless defined? ::Gem return nil unless gemspec @specification = ::Gem::Specification.load(gemspec) end |
.specification! ⇒ Object
29 30 31 32 33 34 |
# File 'lib/lookout/rake/tasks.rb', line 29 def specification! specification or raise ArgumentError, 'gem specification was not given and could not be found in project root: %s' % top_srcdir end |
.top_srcdir ⇒ Object
14 15 16 |
# File 'lib/lookout/rake/tasks.rb', line 14 def top_srcdir @top_srcdir ||= Dir.pwd end |