Rust - Vim Setup For Dummies

Before any Gopher will start yell at me - no, I’m not bailing on Go, I’m just checking what other options I can have to build VSTs instead of C++…

Getting Vim to work with Rust

I’ll try to be as quick as possible here:

  1. Get Vim (no doy…)
  2. Install Rust
  3. Install coc and rust vim with your favourite plugin manager
  4. Install Rust-analyzer
  5. Run in Vim: CocInstall coc-rust-analyzer - more info here
  6. Add let g:rustfmt_autosave = 1 to your .vimrc to run rustfmt (autoformatting) on save

At step 5, Vim might ask you to install some extra stuff - just roll with it!

If you have any questions, suggestions or anything else - grab me on linkedin!

Written on June 8, 2021