
Rust环境配置

在日用 manjaro 上配置基本 Rust 开发环境
Rust on manjaro
install Rust
by curl
install curl
1
2sudo pacman -Syu
sudo pacman -S curlinstall Rust
1
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
activate
1
2source ~/.profile
source ~/.cargo/envop
1
2
3rustc --v
cargo --version
rustup --version
run
by rustc
1 | rustc file-name.rs |
by cargo
create new project
1
cargo new project-name
run
1
cargo run
update Rust
by rustup
1 | rustup self update |
uninstall Rust
by rustup
1 | rustup self uninstall |