Unless you need the latest, bleeding edge version of Rust, do apt-cache search rust to see which Ubuntu packages provide which versions of rust. For initial learning, one doesn't need the absolute latest, and it's "best" if you don't "accidentally" find yourself at war (or confusion) with the packaging system.
How to install rust?
Installing rust in windows without VisualStudio
proxy - How can I install Rust using rustup on Windows when behind a firewall? - Stack Overflow
How to install rust with clang profile?
Videos
Hey I’m a newbie and I’m using vscode, I installed the officially extension but uninstalled it due to seeing post that it’s bad, what do I use to run rust? I’ve installed it in the command line already.
Unless you need the latest, bleeding edge version of Rust, do apt-cache search rust to see which Ubuntu packages provide which versions of rust. For initial learning, one doesn't need the absolute latest, and it's "best" if you don't "accidentally" find yourself at war (or confusion) with the packaging system.
If not installing system wide, then you should probably be in your user's $HOME directory ~/ instead of / so just run cd or cd ~/ before you run the curl stuff.
Your user does not own or have permission to write files to your current directory which is your root directory /. You can see your current directory indicated before the dollar sign at your prompt kdsouza@bsc-848851112:/$
Any one of the following sets of commands listed below will do the same thing, that is, change to your user's home directory before downloading and running the installation script. Your user's home directory will be indicated by the tilde sign ~ as your current directory shown at ypur prompt kdsouza@bsc-848851112:~$
cd
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
or
cd ~/
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
or
cd $HOME
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
Running the cd command with no directory specified (first command) shoud change to your home directory by default.
Alternatively, running the cd command along with a directory will change to whatever directory you specify. Your user's home directory is /home/username/ where username is your current username so probably /home/kdsouza.
$HOME and ~ and ~/ and even /home/$USER will all be interpreted by bash as the same thing, /home/kdsouza. So you can cd to any one of these to get to your home directory.
Either that or there's no space left on your device although it usually says something like no space left on device in the output when that is the case.
To view your available free space, run the following command:
df -h
The -h flag will list the free space in human readable format.
How can i install rust in windows, without using, Visual Studio.
I've already seen post using mingw_64 but it wasn't very clear...
Thanks for reading :)
I followed aSpex's advice...
- Go to https://www.rust-lang.org/ -> Install
Download rustup-init.exe to ~/Downloads
In powershell:
$proxy='http://<IP>:<PORT>' $ENV:HTTP_PROXY=$proxy $ENV:HTTPS_PROXY=$proxy cd ~\Downloads .\rustup-init.exe
I have tested two solutions that were suggested as comments above, and both worked. Thanks, kennytm and ljedrz!
Suggested by kennytm, add the following line to the hosts file in c:\Windows\System32\drivers\etc
13.32.244.72 static.rust-lang.org
Suggested by ljedrz, use a standalone installer. In the past, one could easily find those standalone installers, but with the latest reorg of the rust language site, the only thing really pops out initially is the rustup-init.exe. However as @ljedrz pointed out in his comment above, those standalone installers still exist and can be found here: standalone installers for various platforms.