diff options
Diffstat (limited to 'lib/bundler/definition.rb')
-rw-r--r-- | lib/bundler/definition.rb | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/lib/bundler/definition.rb b/lib/bundler/definition.rb index 6b2c4c1633..63681886b2 100644 --- a/lib/bundler/definition.rb +++ b/lib/bundler/definition.rb @@ -32,6 +32,20 @@ module Bundler end end + def index + @index ||= Index.build do |idx| + sources.each do |s| + idx.use s.local_specs + end + end + end + + def remote_index + @remote_index ||= Index.build do |idx| + sources.each { |source| idx.use source.specs } + end + end + def no_sources? sources.length == 1 && sources.first.remotes.empty? end |