@@ -26,19 +26,28 @@ see the website][platform-support].
26
26
27
27
## Installing Rust
28
28
29
- All we need to do is open a terminal and type this:
29
+ All we need to do on On Unix systems like Linux and macOS is open a
30
+ terminal and type this:
30
31
31
32
``` bash
32
33
$ curl https://sh.rustup.rs -sSf | sh
33
34
```
34
35
35
- This will download a script, and start the installation. If it all goes well,
36
- you’ll see this appear:
36
+ That will download a script, and start the installation. If it all
37
+ goes well, you’ll see this appear:
37
38
38
39
``` text
39
40
Rust is installed now. Great!
40
41
```
41
42
43
+ Installing on Windows is nearly as easy: download and run
44
+ [ rustup-init.exe] . It will run the installation in a console and
45
+ present the above message on success. For other installation options
46
+ and information, visit the [ install] page of the Rust website.
47
+
48
+ [ rustup-init.exe ] : https://win.rustup.rs
49
+ [ install ] : https://www.rust-lang.org/install.html
50
+
42
51
## Uninstalling
43
52
44
53
Uninstalling Rust is as easy as installing it:
@@ -59,12 +68,16 @@ You should see the version number, commit hash, and commit date.
59
68
60
69
If you do, Rust has been installed successfully! Congrats!
61
70
62
- If you don't and you're on Windows, check that Rust is in your %PATH% system
63
- variable: ` $ echo %PATH% ` . If it isn't, run the installer again, select "Change"
64
- on the "Change, repair, or remove installation" page and ensure "Add to PATH" is
65
- installed on the local hard drive. If you need to configure your path manually,
66
- you can find the Rust executables in a directory like
67
- ` "C:\Program Files\Rust stable GNU 1.x\bin" ` .
71
+ If you don't, that probably means that the ` PATH ` environment variable
72
+ doesn't include Cargo's binary directory, ` ~/.cargo/bin ` on Unix, or
73
+ ` %USERPROFILE%\.cargo\bin ` on Windows. This is the directory where
74
+ Rust development tools live, and most Rust developers keep it in their
75
+ ` PATH ` environment variable, which makes it possible to run ` rustc ` on
76
+ the command line. Due to differences in operating systems, command
77
+ shells, and bugs in installation, you may need to restart your shell,
78
+ log out of the system, or configure ` PATH ` manually. If necessary,
79
+ configure your ` PATH ` variable as appropriate for your operating
80
+ environment.
68
81
69
82
Rust does not do its own linking, and so you’ll need to have a linker
70
83
installed. Doing so will depend on your specific system. For
0 commit comments