Class: Bundler::Dependencies::Visitors::Paths
- Inherits:
-
Object
- Object
- Bundler::Dependencies::Visitors::Paths
- Defined in:
- lib/bundler/dependencies/visitors/paths.rb
Instance Method Summary collapse
Instance Method Details
#walk(graph, name, acc = [], key = []) ⇒ Object
5 6 7 8 9 10 11 12 13 14 15 |
# File 'lib/bundler/dependencies/visitors/paths.rb', line 5 def walk(graph, name, acc = [], key = []) graph.each do |gem| next unless gem.include_dependency?(name) new_key = key.dup.push(gem.name) walk(gem.dependencies, name, acc, new_key) acc << (new_key << name) if gem.dependencies.include?(name) end acc end |