Skip to content

Commit afdf053

Browse files
Add common commands section in help text
Judging from user feedback coming out of Debian distros, it appears that after installing `rustup` from the package manager it is not immediately clear which command installs the toolchain. This patch adds a small text so that after installation of `rustup`, which normally does not invoke the toolchain installation for the user, the user can still receive guidance on how to set up the local toolchain immediately. Signed-off-by: Xiangfei Ding <dingxiangfei2009@protonmail.ch>
1 parent c75045d commit afdf053

File tree

4 files changed

+76
-5
lines changed

4 files changed

+76
-5
lines changed

src/cli/help.rs

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,18 @@ pub(crate) fn rustup_help() -> String {
1111
for common platforms.
1212
1313
If you are new to Rust consider running `rustup doc --book` to
14-
learn Rust."
14+
learn Rust.
15+
16+
{HEADER}Common commands:{HEADER:#}
17+
18+
Update Rust toolchains and rustup
19+
20+
{LITERAL}$ rustup update{LITERAL:#}
21+
22+
Install the current stable release of Rust for your host platform
23+
24+
{LITERAL}$ rustup toolchain install stable{LITERAL:#}
25+
"
1526
)
1627
}
1728

tests/suite/cli_rustup_ui/rustup_help_cmd.stdout.term.svg

Lines changed: 21 additions & 1 deletion
Loading

tests/suite/cli_rustup_ui/rustup_help_flag.stdout.term.svg

Lines changed: 21 additions & 1 deletion
Loading

tests/suite/cli_rustup_ui/rustup_only_options.stderr.term.svg

Lines changed: 22 additions & 2 deletions
Loading

0 commit comments

Comments
 (0)