diff --git a/README.md b/README.md index c7f3819..1f9c19a 100644 --- a/README.md +++ b/README.md @@ -108,7 +108,7 @@ If mise is responsible for installing Rust in your workflow, opt in to Rust tool cache_rust: true ``` -When enabled, the action exports `MISE_RUSTUP_HOME` and `MISE_CARGO_HOME` to directories under the mise data dir before cache restore and install. Those directories are then restored and saved with the normal mise cache. The default cache key includes a `-rust` segment when this option is enabled so Rust-enabled caches do not reuse older mise-only caches. If you override `cache_key`, include `{{cache_rust}}` or otherwise invalidate that key when enabling this option. +When enabled, the action exports `MISE_RUSTUP_HOME` and `MISE_CARGO_HOME` to directories under the mise data dir before cache restore and install. Those directories are then restored and saved with the normal mise cache. With the default `env: true`, mise may also export `RUSTUP_HOME` and `CARGO_HOME` for later workflow steps so plain `cargo`, `rustfmt`, and `clippy` commands use the same cached homes. The default cache key includes a `-rust` segment when this option is enabled so Rust-enabled caches do not reuse older mise-only caches. If you override `cache_key`, include `{{cache_rust}}` or otherwise invalidate that key when enabling this option. Leave `cache_rust` as `false` when Rust is installed or cached by another action such as `rustup`, `actions-rust-lang/setup-rust-toolchain`, or `Swatinem/rust-cache`, and you use mise for other tools. `Swatinem/rust-cache` remains useful alongside this option for Cargo registry, git dependency, and `target` build artifact caching. diff --git a/action.yml b/action.yml index a3947ef..861af58 100644 --- a/action.yml +++ b/action.yml @@ -64,6 +64,10 @@ inputs: rustup metadata, and cargo/rustup proxy binaries that mise needs for Rust components such as rustfmt and clippy. + With the default `env: true`, mise may also export `RUSTUP_HOME` and + `CARGO_HOME` for later workflow steps so plain `cargo`, `rustfmt`, and + `clippy` commands use the same cached homes. + Default `false` keeps existing workflows unchanged, especially jobs that install Rust with rustup, rust-cache, setup-rust-toolchain, or another standard Rust action and use mise only for other tools.