From 7041bdce556a4e11bc1687a77ae4d81e6596cef8 Mon Sep 17 00:00:00 2001 From: Nando Vieira Date: Wed, 8 Oct 2025 15:17:18 -0700 Subject: [PATCH] Deprecate `stellar --list` in favor of `stellar plugin ls`. --- FULL_HELP_DOCS.md | 2 +- cmd/crates/soroban-test/tests/it/plugin.rs | 5 +++-- cmd/soroban-cli/src/commands/global.rs | 2 +- cmd/soroban-cli/src/commands/mod.rs | 2 ++ 4 files changed, 7 insertions(+), 4 deletions(-) diff --git a/FULL_HELP_DOCS.md b/FULL_HELP_DOCS.md index 001cc3a002..60f533a3c8 100644 --- a/FULL_HELP_DOCS.md +++ b/FULL_HELP_DOCS.md @@ -68,7 +68,7 @@ Anything after the `--` double dash (the "slop") is parsed as arguments to the c - `-q`, `--quiet` — Do not write logs to stderr including `INFO` - `-v`, `--verbose` — Log DEBUG events - `--very-verbose` [alias: `vv`] — Log DEBUG and TRACE events -- `--list` — List installed plugins. E.g. `stellar-hello` +- `--list` — ⚠️ Deprecated, use `stellar plugin ls`. List installed plugins. E.g. `stellar-hello` - `--no-cache` — Do not cache your simulations and transactions ## `stellar contract` diff --git a/cmd/crates/soroban-test/tests/it/plugin.rs b/cmd/crates/soroban-test/tests/it/plugin.rs index ff1fd1ecde..01fc143a8f 100644 --- a/cmd/crates/soroban-test/tests/it/plugin.rs +++ b/cmd/crates/soroban-test/tests/it/plugin.rs @@ -34,10 +34,11 @@ fn stellar_bye() { #[test] fn list() { - // Call `soroban --list` with the PATH variable set to include the target/bin directory + // Call `stellar plugin ls` with the PATH variable set to include the target/bin directory assert_cmd::Command::cargo_bin("stellar") .unwrap_or_else(|_| assert_cmd::Command::new("stellar")) - .arg("--list") + .arg("plugin") + .arg("ls") .env("PATH", get_paths()) .assert() .stdout(predicates::str::contains("hello")) diff --git a/cmd/soroban-cli/src/commands/global.rs b/cmd/soroban-cli/src/commands/global.rs index 02c0b3b58e..02579f81fb 100644 --- a/cmd/soroban-cli/src/commands/global.rs +++ b/cmd/soroban-cli/src/commands/global.rs @@ -39,7 +39,7 @@ pub struct Args { #[arg(long, visible_alias = "vv", global = true, help_heading = HEADING_GLOBAL)] pub very_verbose: bool, - /// List installed plugins. E.g. `stellar-hello` + /// ⚠️ Deprecated, use `stellar plugin ls`. List installed plugins. E.g. `stellar-hello` #[arg(long)] pub list: bool, diff --git a/cmd/soroban-cli/src/commands/mod.rs b/cmd/soroban-cli/src/commands/mod.rs index c51619bc99..d3203fbbb6 100644 --- a/cmd/soroban-cli/src/commands/mod.rs +++ b/cmd/soroban-cli/src/commands/mod.rs @@ -87,6 +87,8 @@ impl Root { pub fn new() -> Result { Self::try_parse().map_err(|e| { if std::env::args().any(|s| s == "--list") { + let print = Print::new(std::env::args().any(|s| s == "--quiet" || s == "-q")); + deprecate_message(print, "--list", "Use `stellar plugin ls` instead."); let _ = plugin::ls::Cmd.run(); std::process::exit(0); }