Onebite.dev
Developer tips & trick, one bite at a time
Let’s set up our Rust development environment,
You can play Rust online, without installing anything. Play Rust Lang
The recommended way to install Rust is using Rustup. It’s both installer and version manager for Rust
For macOs / Linux
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
Using other OS? check other installation method here
Rust updates frequently. Run rustup update
to user the latest update.
When we install Rustup, we also install Cargo. It does a lot of things
cargo build
cargo run
cargo test
cargo doc
cargo publish
To make sure everything is installed. Run cargo --version
Whatever text-editor you use, make sure to install Rust support (syntax highlight or snippets) to make your experience better
When you install Rust, it also copy the documentation locally to read offline.
Try rustup doc
to open it in browser (locally).
You can run
rustup self uninstall
This is a post in the start learning Rust series.