10

Bundler will automatically install any dependencies for the specified gems, however it doesn't output which dependencies map to which gems in the standard output. That information is useful when one of the dependencies fails the installation.

Is there a way to set Bundler to be more verbose and inform about the dependencies while installing?

I am using Bundler 1.0.2

the Tin Man
  • 158,662
  • 42
  • 215
  • 303
Samer Buna
  • 8,821
  • 9
  • 38
  • 55

2 Answers2

11

To see a visual representation of the dependency tree run bundle viz:

apt-get install graphviz && gem install ruby-graphviz && bundle viz

It will generate a PNG file of the tree.

the Tin Man
  • 158,662
  • 42
  • 215
  • 303
Samer Buna
  • 8,821
  • 9
  • 38
  • 55
7

A less exciting, but equally effective way is to just do:

gem dep

which will generate a Gemfile.lock style output with dependency information. You could pipe this output to less:

gem dep | less

Or, if you are searching for a failing dependency, you could grep it with some context. For instance, to find out where my failing Thin dependency was coming from (fails with JRuby), I did:

gem dep | grep -C 15 thin
the Tin Man
  • 158,662
  • 42
  • 215
  • 303
ipd
  • 5,674
  • 3
  • 34
  • 49