How do I tell VS code what toolchain I want to use?

RustVisual Studio-Code

Rust Problem Overview


After installing extensions for Rust, I get this error:

> To properly function, the extension needs to know what toolchain you > want to use.

Rust Solutions


Solution 1 - Rust

Press Close to select toolchain :)

Solution 2 - Rust

The extension will provide a prompt after you close that prompt, which allows you to select the toolchain you want. You can see the toolchain that you selected in your preferences file.

Solution 3 - Rust

As the message says, you must choose a toolchain (documentation here):

$ rustup default stable

for the stable Rust, or

$ rustup default nightly

for the newest development version.

If you only want to play with Rust, I advise you to use nightly Rust because there are more new things in it.

Solution 4 - Rust

Add this to your configuration with toolchain you want to use to enforce it in VS Code:

"rust.rustup": {
    "toolchain": "stable-x86_64-apple-darwin"
  }

Attributions

All content for this solution is sourced from the original question on Stackoverflow.

The content on this page is licensed under the Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) license.

Content TypeOriginal AuthorOriginal Content on Stackoverflow
QuestionMTech2008View Question on Stackoverflow
Solution 1 - RustStepan YakovenkoView Answer on Stackoverflow
Solution 2 - Rustuser3704639View Answer on Stackoverflow
Solution 3 - RustBoiethiosView Answer on Stackoverflow
Solution 4 - RustIvan TemchenkoView Answer on Stackoverflow