fix(yank): Use '--version' like install#10575
Conversation
|
r? @ehuss (rust-highfive has picked a reviewer for you, use r? to override) |
During the design conversations on cargo-add, we noticed that `cargo-install` has a public flag `--version` and an invisible alias `--vers` while `cargo-yank` has a public flag `--vers`. This switches `cargo-yank` to publicly use `--version` and have an invisible alias `--vers`, making them consistent. Completions are a best guess.
f0998dc to
2313edd
Compare
weihanglo
left a comment
There was a problem hiding this comment.
Looks reasonable!
For completion, it makes sense that --vers is not there, since it's not recommended any more. For doc, it should be there for people to lookup. I believe cargo will continue supporting --vers for a long time. Does these answer your uncertainties?
I actually don't remember why I listed those areas of uncertainty as I had just copied what |
This comment was marked as duplicate.
This comment was marked as duplicate.
|
@rfcbot merge It's a user-facing change, so I'd like to get feedback from the team. Generally it seems no harm and more consistent. |
|
Team member @weihanglo has proposed to merge this. The next step is review by the rest of the tagged team members: No concerns currently listed. Once a majority of reviewers approve (and at most 2 approvals are outstanding), this will enter its final comment period. If you spot a major issue that hasn't been raised at any point in this process, please speak up! See this document for info about what commands tagged team members can give me. |
|
🔔 This is now entering its final comment period, as per the review above. 🔔 |
|
Seems reasonable. We already have other commands accepting |
|
Thanks everyone! @bors r+ |
|
📌 Commit 2313edd has been approved by |
|
☀️ Test successful - checks-actions |
Update cargo 8 commits in edffc4ada3d77799e5a04eeafd9b2f843d29fc23..f63f23ff1f1a12ede8585bbd1bbf0c536e50293d 2022-04-19 17:38:29 +0000 to 2022-04-28 03:15:50 +0000 - move workspace inheritance untable docs to the correct place (rust-lang/cargo#10609) - Cargo add support for workspace inheritance (rust-lang/cargo#10606) - chore: Upgrade toml_edit (rust-lang/cargo#10603) - Mark .cargo/git and .cargo/registry as cache dirs (rust-lang/cargo#10553) - fix(yank): Use '--version' like install (rust-lang/cargo#10575) - Disallow setting registry tokens with --config (rust-lang/cargo#10580) - Set cargo --version git hash length to 9 (rust-lang/cargo#10579) - Prefer `key.workspace = true` to `key = { workspace = true }` (rust-lang/cargo#10584)
What does this PR try to resolve?
During the design conversations on cargo-add, we noticed:
cargo-installhas a public flag--versionand an invisible alias--verscargo-yankhas a public flag--versThis switches
cargo-yankto publicly use--versionand have an invisible alias--vers, making it consistent withcargo-install.How should we test and review this PR?
This updated all tests to use the "recommended" flag.