-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
feat: Support '-F' as an alias for '--features' #10576
Conversation
This decision was part of rust-lang#10472 - It looks like all commands except `cargo-add` are using the prelude to define `--features`, so this should hit them all. - I've updated completions to the best of my knowledge. - It appears we don't need to update man pages or other documentation. - I'm assuming we don't add tests for every sort flag but rely on clap to have coverage to ensure it works.
r? @ehuss (rust-highfive has picked a reviewer for you, use r? to override) |
Hmm… I still love to see them mentioned in manpages for users to discover this new alias when running |
The manual change is to `src/doc/man/includes/section-features.md`, the rest is code-generated.
Done |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great. Thanks!
@bors r+ |
📌 Commit f728045 has been approved by |
☀️ Test successful - checks-actions |
Update cargo 7 commits in dba5baf4345858c591517b24801902a062c399f8..edffc4ada3d77799e5a04eeafd9b2f843d29fc23 2022-04-13 21:58:27 +0000 to 2022-04-19 17:38:29 +0000 - Document cargo-add (rust-lang/cargo#10578) - feat: Support '-F' as an alias for '--features' (rust-lang/cargo#10576) - Completion support for `cargo-add` (rust-lang/cargo#10577) - Add a link to the document in the timings report (rust-lang/cargo#10492) - feat: Import cargo-add into cargo (rust-lang/cargo#10472) - Part 8 of RFC2906 - Keep `InheritableFields` in a `LazyCell` inside `… (rust-lang/cargo#10568) - Part 7 of RFC2906 - Add support for inheriting `exclude` and `include` (rust-lang/cargo#10565)
165: Support short flags of --release and --features r=taiki-e a=taiki-e - `--release` (`-r`) rust-lang/cargo#10133 - `--features` (`-F`) rust-lang/cargo#10576 Co-authored-by: Taiki Endo <te316e89@gmail.com>
150: Support short flag of --features r=taiki-e a=taiki-e refs: rust-lang/cargo#10576 Co-authored-by: Taiki Endo <te316e89@gmail.com>
Cargo also does this in nightly channel: rust-lang/cargo#10576
Addition of support for -F as an alias for --features Updated documentation for #10576
What does this PR try to resolve?
Adds a short flag
-F
for--features to all cargo commands to be consistent with the
-F` short flag being added in #10472.How should we test and review this PR?
The decision for this is a part of #10472 which is in FCP.
cargo-add
are using the prelude todefine
--features
, so this should hit them all.to have coverage to ensure it works.
Review the commits separately. For the documentation change, the only manual change is in
src/doc/man/includes/section-features.md
, the rest are code-generated.