Getting Started

Installing Rust on Arch is a little weird because it doesn't use the officially supported method.

sudo pacman -S rustup
rustup toolchain install stable
rustup default stable

Vim integration

Install the official vim plugin with:

Plug 'rust-lang/rust.vim'

Then install the Rust CoC extension with:

:CocInstall coc-rls

Hello, Rust!

Now that Rust is installed and configured we can actually make something.

cargo new hello-rust

This creates a new folder called hello-rust with some files to get started with. When opening in vim for the first time it may prompt you to install RLS. Accept that and some more files/folders will be created, AFAIK right now it's safe to add these to .gitignore (usually target/).

Next you can modify the code in src/ or simply run cargo run to compile and run the code.


Content properties

  • Type: Note
  • Category: Rust
  • Tags: backend
  • Custom slug: None

This is a preview of a simpler page design that I'm working on over the next little bit. I've finally added a (click it!) but there's still a few pages left to be converted so don't worry if things don't look quite right just yet 🙏

Content on blog pages use the CC-BY-SA license. The source code and notes use the MIT license. Unsure? Mention me on Mastodon.