Getting Started with Rust

Michael Krisher
6 min readJan 17, 2024

Compared to the Ruby ecosystem

This is another post in my series about learning Rust through Ruby. Or comparing Rust to Ruby in the context of learning the syntax and ecosystem. The first thing we want to do is get things set up locally. Let’s dive in and compare.

Photo by Joshua Fuller on Unsplash

With Ruby, you can simply install the runtime on your machine and begin. A lot of people in the community will use a version manager like RVM or [rbenv]. Rust doesn’t have an equivalent in that you switch between different versions of Rust by semantic version. There are toolchains, which can be thought of as versions, but I’ll get into those in a bit. With Rust, you can have a fair bit of confidence that developing on the latest stable version is the way to go. Before we get too ahead of ourselves, let’s install Rust.

The recommended way to install Rust locally is via rustup. Essentially, you are running a shell script that installs an executable–the Rust compiler.

* Note: we didn’t simply say use homebrew or other package manager

Rustup gets us the latest “version” of the Rust compiler. Notice “versions” is in quotes. Officially, Rust calls these toolchains. A toolchain is made up of a release channel and the compilation targets. If you are on a Mac, your compilation target is MacOS. There are three release channels. Nightly, beta, and…

--

--