From eedfe97e7d3cbacc590fda3a03f65314d002e6c7 Mon Sep 17 00:00:00 2001 From: Roland Schaer Date: Tue, 14 Jan 2025 11:46:50 -0300 Subject: [PATCH] feat: allow to specify Rust profile --- docs/lang/rust.md | 19 +++++++++++++++++++ src/cmd.rs | 7 +++++++ src/plugins/core/rust.rs | 8 ++++++++ 3 files changed, 34 insertions(+) diff --git a/docs/lang/rust.md b/docs/lang/rust.md index 2520cabbb8..7a75361f9e 100644 --- a/docs/lang/rust.md +++ b/docs/lang/rust.md @@ -32,6 +32,25 @@ mise use -g rust@1.82 cargo build ``` +## Tool Options + +The following [tool-options](/dev-tools/#tool-options) are available for the `rust` backend—these +go in `[tools]` in `mise.toml`. + +### `profile` + +The `profile` option allows you to specify the type of release to install. The following values +are supported: + +- `minimal`: Includes as few components as possible to get a working compiler (rustc, rust-std, and cargo) +- `default` (default): Includes all of components in the minimal profile, and adds rust-docs, rustfmt, and clippy +- `complete`: Includes all the components available through rustup. This should never be used, as it includes every component ever included in the metadata and thus will almost always fail. + +```toml +[tools] +"rust" = { version = "1.83.0", profile = "minimal" } +``` + ## Settings