Direct dependencies

58 views
Skip to first unread message

Gemma Cabero Colmenero

unread,
Sep 28, 2022, 8:25:46 AM9/28/22
to license-finder
Hi,

Does license_finder offer an option to just pull the direct dependencies only?
 
I wonder how I could reduce the output of a rust project to produce the same as the output (in terms on dependencies found) as cargo license which seems to have some good options like --direct-deps-only or --avoid-dev-deps

$>cargo license -t --direct-deps-only

Many thanks,
Gemma



Shane Lattanzio

unread,
Sep 28, 2022, 1:10:49 PM9/28/22
to license-finder

Hey,

If you look at cargo.rb, you can see the commands that are being ran for cargo projects. If there are better ways to handle that package manager, we would be open to suggestions and any PRs that come in. Since we are not experts in every package manager, we let the community drive a lot of that.

Currently it looks like `cargo metadata --format-version=1` is being ran and then parsed out to find the relevant information. As for the flags you suggest, we could have a command like option like we have with maven for example, but we would need to have a PR for that as well.

- Shane
Reply all
Reply to author
Forward
0 new messages