Moving Rust install-tree

I just reinstalled Rust on Win-10 using the rustup-init.exe program. This had no option
to select the install-directory AFAICS.

So all files ended up under f:\ProgramFiler\Rust (the value of %ProgramFiles%).
I keep other programming languages under f:\gv\Prog. So in style with this, I moved everything from f:\ProgramFiler\Rust to f:\gv\Prog\Rust and changed these env-vars:

set CARGO_HOME=f:\gv\Prog\Rust\Cargo
set RUSTUP_HOME=f:\gv\Prog\Rust\Rustup

Is this safe? Are there other env-vars or settings in some obscure files that need a change?

I tested the new install-tree with building RustTls. I found no issues.

I recommend scoop, you can just run scoop install rustup, it installs rustup under scoop apps, but will persist the .rustup and .cargo directory, and set RUSTUP_HOME and CARGO_HOME automatically.

https://scoop.sh/

it respect the RUSTUP_HOME and CARGO_HOME env variables. you need to set these before running rustup-init.exe, see "choose where to install" section:

https://rust-lang.github.io/rustup/installation/index.html#choosing-where-to-install

these two variables should be enough.

also, don't forget to to add %CARGO_HOME%\bin to PATH

these two variables should be enough.

Thanks, that's a relief.

also, don't forget to to add %CARGO_HOME%\bin to PATH

Sure I have that.