cargo-tree
cargo-tree copied to clipboard
Add JSON output capabilities
I needed this to be able to output JSON for parsing elsewhere.
Have you taken a look at cargo metadata
? That's the main interface for interacting programmatically with Cargo.
Unfortunately cargo metadata
doesn't output any information on resolved features, which I need, and also doesn't output a tree, which is handy for my use-case. While I could munge it into the right format, it seemed like a better option to reuse cargo-tree
, since that's basically what it does already. I don't mind keeping this local if you don't want machine-friendly formats in cargo-tree
, though.
What do you mean by resolved features?
I would kind of like to keep this project focused on user-facing output.