Class: Bundler::Dsl

Inherits:
Object
  • Object
show all
Defined in:
lib/development.rb

Instance Method Summary collapse

Instance Method Details

#gem(nm_gem, opt_gem = {}) ⇒ Object



8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
# File 'lib/development.rb', line 8

def gem(nm_gem, opt_gem = {})
  shome = File.expand_path('../..', __FILE__)
  gem_info = File.join(shome, ".local", nm_gem)
  if File.exists? gem_info
    source "http://localhost:9292"
    local_opt = { :path => File.read(gem_info).strip }

    unless local_opt[:path].empty?
      gex nm_gem, local_opt
    else
      gex nm_gem, opt_gem.clone
    end
  else
    gex nm_gem, opt_gem.clone
  end
end

#gexObject



4
# File 'lib/development.rb', line 4

alias :gex :gem