fix: clarify rust cache setup logs

This commit is contained in:
Taku Kodma 2026-05-10 20:32:12 +10:00
parent 17411053db
commit 533c03f222
No known key found for this signature in database
GPG key ID: 2FA149ECEAB1E16D
3 changed files with 17 additions and 5 deletions

View file

@ -167,18 +167,25 @@ async function setupRustCache(): Promise<void> {
)
return
}
if (!core.getBooleanInput('cache_save')) {
core.warning(
'cache_rust is enabled, but cache_save is false. Rust cache paths will be restored for this run but not saved.'
)
}
const { rustupHome, cargoHome } = rustCacheHomes()
if (process.env.MISE_RUSTUP_HOME) {
core.info(`mise rust cache: using MISE_RUSTUP_HOME=${rustupHome}`)
core.info(`mise rust cache: using pre-set MISE_RUSTUP_HOME=${rustupHome}`)
} else {
core.info(`mise rust cache: exporting MISE_RUSTUP_HOME=${rustupHome}`)
core.exportVariable('MISE_RUSTUP_HOME', rustupHome)
}
if (process.env.MISE_CARGO_HOME) {
core.info(`mise rust cache: using MISE_CARGO_HOME=${cargoHome}`)
core.info(`mise rust cache: using pre-set MISE_CARGO_HOME=${cargoHome}`)
} else {
core.info(`mise rust cache: exporting MISE_CARGO_HOME=${cargoHome}`)
core.exportVariable('MISE_CARGO_HOME', cargoHome)
}