Class: Jeweler::Tasks

Inherits:
Rake::TaskLib
  • Object
show all
Defined in:
lib/jeweler/tasks.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(gemspec = nil) {|@gemspec| ... } ⇒ Tasks

Returns a new instance of Tasks.

Yields:



12
13
14
15
16
17
18
19
# File 'lib/jeweler/tasks.rb', line 12

def initialize(gemspec = nil, &block)
  @gemspec = gemspec || Gem::Specification.new
  @jeweler = Jeweler.new(@gemspec)
  yield @gemspec if block_given?

  Rake.application.jeweler = @jeweler
  define
end

Instance Attribute Details

#gemspecObject

Returns the value of attribute gemspec.



10
11
12
# File 'lib/jeweler/tasks.rb', line 10

def gemspec
  @gemspec
end

#jewelerObject

Returns the value of attribute jeweler.



10
11
12
# File 'lib/jeweler/tasks.rb', line 10

def jeweler
  @jeweler
end