Skip to content

Commit c475ebe

Browse files
committed
fix: make deprecated cmds more obvious in help and --list
1 parent 642453a commit c475ebe

File tree

4 files changed

+6
-6
lines changed

4 files changed

+6
-6
lines changed

src/bin/cargo/commands/git_checkout.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ const REMOVED: &str = "The `git-checkout` command has been removed.";
66

77
pub fn cli() -> Command {
88
subcommand("git-checkout")
9-
.about("This command has been removed")
9+
.about("REMOVED: This command has been removed")
1010
.hide(true)
1111
.override_help(REMOVED)
1212
}

src/bin/cargo/commands/read_manifest.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@ pub fn cli() -> Command {
77
.hide(true)
88
.about(color_print::cstr!(
99
"\
10-
Print a JSON representation of a Cargo.toml manifest.
10+
DEPRECATED: Print a JSON representation of a Cargo.toml manifest.
1111
12-
Deprecated, use `<cyan,bold>cargo metadata --no-deps</>` instead.\
12+
Use `<cyan,bold>cargo metadata --no-deps</>` instead.\
1313
"
1414
))
1515
.arg_silent_suggestion()

src/bin/cargo/commands/verify_project.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@ pub fn cli() -> Command {
1010
.hide(true)
1111
.about(
1212
"\
13-
Check correctness of crate manifest.
13+
DEPRECATED: Check correctness of crate manifest.
1414
15-
Deprecated, see https://github.com/rust-lang/cargo/issues/14679.",
15+
See https://github.com/rust-lang/cargo/issues/14679.",
1616
)
1717
.arg_silent_suggestion()
1818
.arg_manifest_path()

tests/testsuite/cargo_command.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ fn list_commands_with_descriptions() {
3636
...
3737
r alias: run
3838
...
39-
read-manifest Print a JSON representation of a Cargo.toml manifest.
39+
read-manifest DEPRECATED: Print a JSON representation of a Cargo.toml manifest.
4040
...
4141
t alias: test
4242
...

0 commit comments

Comments
 (0)