Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

List dependency feature flag in cargo search foo #11289

Closed
flipchan opened this issue Oct 26, 2022 · 2 comments
Closed

List dependency feature flag in cargo search foo #11289

flipchan opened this issue Oct 26, 2022 · 2 comments
Labels
C-feature-request Category: proposal for a feature. Before PR, ping rust-lang/cargo if this is not `Feature accepted`

Comments

@flipchan
Copy link

Problem

Hey,
Is it possible to add the option for listing feature flags with cargo search?
It would be really handy to be able to:

cargo search --show-features foo

Right now there is no option for viewing feature flags with cargo search so the user got to go to crates.io and check the feature flags.

Proposed Solution

cargo search --show-features foo

Notes

Functionality to display feature flags with cargo search

@flipchan flipchan added the C-feature-request Category: proposal for a feature. Before PR, ping rust-lang/cargo if this is not `Feature accepted` label Oct 26, 2022
@epage
Copy link
Contributor

epage commented Oct 26, 2022

We have a separate request for a cargo info which imo would be a better fit for this as the intent and display format for cargo search wouldn't quite work well for this.

Workarounds:

  • Install cargo info
  • Run cargo add foo --dry-run (you could make an alias of this if you want)

@ehuss
Copy link
Contributor

ehuss commented Dec 11, 2022

This does seem like something that would be nice to have. I agree that it probably doesn't fit with cargo search very well. I'm going to close as a duplicate of #948, which I think would be a potentially good use case for this, as well as the existing cargo add --dry-run and cargo info.

@ehuss ehuss closed this as not planned Won't fix, can't repro, duplicate, stale Dec 11, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-feature-request Category: proposal for a feature. Before PR, ping rust-lang/cargo if this is not `Feature accepted`
Projects
None yet
Development

No branches or pull requests

3 participants