Skip to content

Commit 4431c3d

Browse files
committed
Make the steps clear
First open a Rust buffer Then update RA settings If you don't open a buffer first then nothing will happen. This is because the plugin makes a raw LSP RPC, so RA must be attached.
1 parent 1147d90 commit 4431c3d

File tree

1 file changed

+11
-3
lines changed

1 file changed

+11
-3
lines changed

Diff for: src/building/suggested.md

+11-3
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,17 @@ stage 0 rustfmt to format them.
3030

3131
For Neovim users there are several options for configuring for rustc. The easiest way is by using
3232
[nlsp-settings](https://github.com/tamago324/nlsp-settings.nvim), which allows for project-local
33-
configuration files with the native LSP. First install the plugin by however you manage your
34-
plugins. Then run `:LspSettings local rust_analyzer` to create a JSON configuration file. Then
35-
just paste the above JSON in.
33+
configuration files with the native LSP. The steps for how to use it are below.
34+
35+
1. First install the plugin
36+
2. Run `:LspSettings local rust_analyzer` while the rust repo is open.
37+
38+
This will create and open a JSON file to put the above JSON in.
39+
40+
3. Open a Rust buffer that causes Rust Analyzer to attach.
41+
4. Run `:LspSettings update rust_analyzer`
42+
43+
The final step must be repeated every time you open Neovim after you open a Rust buffer.
3644

3745
Another way is without a plugin, and creating your own logic in your configuration. The required
3846
Lua for doing so is below.

0 commit comments

Comments
 (0)