Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Document installing to a custom location using CARGO_HOME and RUSTUP_HOME environment variables #1024

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,22 @@ For `zsh`, you must then add the following line in your `~/.zshrc` before
fpath+=~/.zfunc
```

#### Choosing where to install

`rustup` allows you to customise your installation by setting the environment
variables `CARGO_HOME` and `RUSTUP_HOME` before running the `rustup-init`
executable. As mentioned in the [Environment Variables] section, `RUSTUP_HOME`
sets the root rustup folder, which is used for storing installed
toolchains and configuration options. `CARGO_HOME` contains cache files used
by [cargo].

Note that you will need to ensure these environment variables are always
set and that `CARGO_HOME/bin` is in the `$PATH` environment variable when
using the toolchain.

[Environment Variables]: #environment-variables
[cargo]: https://github.com/rust-lang/cargo

## How rustup works

`rustup` is a *toolchain multiplexer*. It installs and manages many
Expand Down