diff options
author | Carl Lerche <carllerche@mac.com> | 2010-01-29 15:14:04 -0800 |
---|---|---|
committer | Carl Lerche <carllerche@mac.com> | 2010-01-29 15:14:04 -0800 |
commit | f329d586cde5a924f1b8e170117e5b6cb96ed9ee (patch) | |
tree | c8acce93390d51065e8d8e36913434cdd56833a7 /lib/bundler/installer.rb | |
parent | 6a344b8cbb0fc6d740a0f0f030f0e427b9c79bfc (diff) | |
download | bundler-f329d586cde5a924f1b8e170117e5b6cb96ed9ee.tar.gz |
Add first round of source pinning support
Diffstat (limited to 'lib/bundler/installer.rb')
-rw-r--r-- | lib/bundler/installer.rb | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/lib/bundler/installer.rb b/lib/bundler/installer.rb index 452577fe..900630eb 100644 --- a/lib/bundler/installer.rb +++ b/lib/bundler/installer.rb @@ -19,11 +19,9 @@ module Bundler return end - without = options[:without] ? options[:without].map {|w| w.to_sym } : [] - specs.each do |spec| next unless spec.source.respond_to?(:install) - next if (spec.groups & without).any? + next if (spec.groups & options[:without]).any? spec.source.install(spec) end @@ -91,9 +89,8 @@ module Bundler index = local_index sources.each do |source| - specs = source.specs Bundler.ui.info "Source: Processing index... " - index = specs.merge(index) + index = source.specs.merge(index).freeze Bundler.ui.info "Done." end @@ -103,10 +100,10 @@ module Bundler def local_index @local_index ||= begin - index = Index.from_installed_gems + index = Index.from_installed_gems.freeze if File.directory?("#{root}/vendor/cache") - index = cache_source.specs.merge(index) + index = cache_source.specs.merge(index).freeze end index |