Skip to content

Commit 012a6d6

Browse files
committed
README: add two rust-analyzer configuration examples for Neovim users
1 parent f295dac commit 012a6d6

1 file changed

Lines changed: 33 additions & 0 deletions

File tree

README.adoc

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,39 @@ These are explained a bit more below, along with some common pitfalls.
9595
[language-server.rust-analyzer.config]
9696
cargo.targetDir = true
9797
----
98+
.Neovim (using rustaceanvim)
99+
[source, lua]
100+
----
101+
vim.g.rustaceanvim = {
102+
server = {
103+
default_settings = {
104+
['rust-analyzer'] = {
105+
cargo = {
106+
targetDir = true,
107+
},
108+
},
109+
},
110+
},
111+
}
112+
----
113+
.Neovim (using LazyVim): merge the following into custom.lua
114+
[source, lua]
115+
----
116+
{
117+
"mrcjkb/rustaceanvim",
118+
opts = {
119+
server = {
120+
default_settings = {
121+
["rust-analyzer"] = {
122+
cargo = {
123+
targetDir = true,
124+
},
125+
},
126+
},
127+
},
128+
},
129+
},
130+
----
98131
99132
====
100133

0 commit comments

Comments
 (0)