Class: Geminabox::Rake

Inherits:
Bundler::GemHelper
  • Object
show all
Defined in:
lib/geminabox/rake.rb

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(dir, name, opts = {}) ⇒ Rake

Returns a new instance of Rake.



15
16
17
18
19
20
21
# File 'lib/geminabox/rake.rb', line 15

def initialize(dir, name, opts = {})
  @hosts     = Array(opts[:host]).map do |host|
    URI.parse(host)
  end
  @namespace = opts[:namespace]
  super File.absolute_path(dir), name
end

Class Method Details

.install_tasks(opts = {}) ⇒ Object Also known as: install



8
9
10
11
# File 'lib/geminabox/rake.rb', line 8

def install_tasks(opts = {})
  opts[:dir] ||= Dir.getwd
  new(opts[:dir], opts[:name], opts).install
end

Instance Method Details

#installObject



23
24
25
26
27
# File 'lib/geminabox/rake.rb', line 23

def install
  namespace geminabox_task_namespace do
    super
  end
end