diff options
author | Carlhuda <carlhuda@engineyard.com> | 2010-02-03 16:40:36 -0800 |
---|---|---|
committer | Carlhuda <carlhuda@engineyard.com> | 2010-02-03 16:40:36 -0800 |
commit | 353f4086d681427fe86b428ab7096d1a1cc65d6e (patch) | |
tree | 339b5cab0e254a4f5ec85d92a862cd979408ae98 /lib/bundler/installer.rb | |
parent | ecec2af4691ff3690995d659bdabc04d87c35368 (diff) | |
download | bundler-353f4086d681427fe86b428ab7096d1a1cc65d6e.tar.gz |
OMG, prioritizing bundler sources is the bane of my existence
Diffstat (limited to 'lib/bundler/installer.rb')
-rw-r--r-- | lib/bundler/installer.rb | 22 |
1 files changed, 14 insertions, 8 deletions
diff --git a/lib/bundler/installer.rb b/lib/bundler/installer.rb index b449202a..2935e244 100644 --- a/lib/bundler/installer.rb +++ b/lib/bundler/installer.rb @@ -53,12 +53,6 @@ module Bundler # Return unless all the dependencies have = version requirements return if dependencies.any? { |d| ambiguous?(d) } - index = local_index - sources.each do |source| - next unless source.respond_to?(:local_specs) - index = source.local_specs.merge(index) - end - source_requirements = {} dependencies.each do |dep| next unless dep.source && dep.source.respond_to?(:local_specs) @@ -118,14 +112,26 @@ module Bundler index = cache_source.specs.merge(index).freeze end - sources.each do |source| + rg_sources = sources.select { |s| s.is_a?(Source::Rubygems) } + other_sources = sources.select { |s| !s.is_a?(Source::Rubygems) } + + other_sources.each do |source| i = source.specs Bundler.ui.debug "Source: Processing index... " index = i.merge(index).freeze Bundler.ui.debug "Done." end - Index.from_installed_gems.merge(index) + index = Index.from_installed_gems.merge(index) + + rg_sources.each do |source| + i = source.specs + Bundler.ui.debug "Source: Processing index... " + index = i.merge(index).freeze + Bundler.ui.debug "Done." + end + + index end end |