Conversation
| } | ||
| Entry::Vacant(e) => { | ||
| pending.push(dep_id); | ||
| if let Some(depth) = max_depth { |
There was a problem hiding this comment.
Technically this check doesn't need to happen because it is taken care of in print_tree(), but it speeds up the common case of just printing the tree (not checking duplicates or starting from an arbitrary package) when a depth limit is specified.
|
Thanks, I'm looking forward to this! :) |
|
Thanks for working on this @mwilliammyers! What does it do if you set the However, I think the ideal solution to #60 would let you show only dependencies referenced directly in your |
|
Assuming |
|
@sfackler if I fix the conflicts with master, is this a feature that you would consider adding? |
Adds the
-D <DEPTH>/--depth <DEPTH>option.Closes #60
Example:
Things to consider:
*printed later on. This might lead to confusing behavior when used with the--duplicateoption though?--packageas the "root" package, i.e. instead of erroring:synis a transitive dependency with a depth>1, it prints out the dependencies ofsynthat have a depth<=1fromsyn(not the real package root):*when truncating a dependency whose children are not being printed because they are above the--depthlimit and is also a duplicate?