applicationsonline / librarian

Librarian - A Framework for Bundlers. Librarian-Chef is at: https://github.com/applicationsonline/librarian-chef.
http://applicationsonline.com/
MIT License
655 stars 71 forks source link

Propose to include nested dependencies in output of "show" command #178

Open nicwaller opened 9 years ago

nicwaller commented 9 years ago

Feature request: I propose that the output of librarian show should include all nested dependencies, not just the first level of dependencies.

My goal is to use Librarian to calculate a complete set of cookbooks and their dependencies, and pass that set as an argument to knife cookbook upload because knife isn't smart enough to resolve dependencies on its own, unless you go with the default behaviour of uploading all cookbooks at once.

Actual Results:

$ librarian-chef show rabbitmq
rabbitmq (2.1.2)
  source: vendor-cookbooks/rabbitmq
  dependencies:
    erlang (>= 0.9)

$ librarian-chef show erlang
erlang (1.3.0)
  source: vendor-cookbooks/erlang
  dependencies:
    apt (>= 1.7.0)
    build-essential (>= 0.0.0)
    yum (>= 0.5.0)

Expected Results:

$ librarian-chef show rabbitmq --recursive
rabbitmq (2.1.2)
  source: vendor-cookbooks/rabbitmq
  dependencies:
    erlang (>= 0.9)
      apt (>= 1.7.0)
      build-essential (>= 0.0.0)
      yum (>= 0.5.0)

I believe this feature could be implemented with minimal changes present_one_dependencies.