diff options
author | bors[bot] <26634292+bors[bot]@users.noreply.github.com> | 2020-04-23 10:11:56 +0100 |
---|---|---|
committer | GitHub <[email protected]> | 2020-04-23 10:11:56 +0100 |
commit | 1101e74b100619802b9538be1e9fea958add1d61 (patch) | |
tree | 865cf4e94967b9d6d472d49b1cc55d265c5edb5c /docs/user | |
parent | 8026a95a2a8a4f1518bacb8c7dd082964daf1193 (diff) | |
parent | 313409af9e230549406e30fe55c4153dadd9cfb2 (diff) |
Merge #4098
4098: Add YouCompleteMe as a LSP option for vim/neovim r=matklad a=weihanglo
As YouCompleteMe supports [arbitrary LSP implementation](https://ycm-core.github.io/YouCompleteMe/#plugging-an-arbitrary-lsp-server), it could be added to the list of vim LSP implementation. It works like a charm.
Co-authored-by: Weihang Lo <[email protected]>
Diffstat (limited to 'docs/user')
-rw-r--r-- | docs/user/readme.adoc | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/docs/user/readme.adoc b/docs/user/readme.adoc index 13ab2acc2..ce5704836 100644 --- a/docs/user/readme.adoc +++ b/docs/user/readme.adoc | |||
@@ -177,6 +177,26 @@ let g:LanguageClient_serverCommands = { | |||
177 | \ } | 177 | \ } |
178 | ---- | 178 | ---- |
179 | 179 | ||
180 | ==== YouCompleteMe | ||
181 | |||
182 | 1. Install YouCompleteMe by following the instructions | ||
183 | https://ycm-core.github.io/YouCompleteMe/#rust-semantic-completion[here] | ||
184 | |||
185 | 2. Configure by adding this to your vim/neovim config file (replacing the existing Rust-specific line if it exists): | ||
186 | + | ||
187 | [source,vim] | ||
188 | ---- | ||
189 | let g:ycm_language_server = | ||
190 | \ [ | ||
191 | \ { | ||
192 | \ 'name': 'rust', | ||
193 | \ 'cmdline': ['rust-analyzer'], | ||
194 | \ 'filetypes': ['rust'], | ||
195 | \ 'project_root_files': ['Cargo.toml'] | ||
196 | \ } | ||
197 | \ ] | ||
198 | ---- | ||
199 | |||
180 | ==== nvim-lsp | 200 | ==== nvim-lsp |
181 | 201 | ||
182 | NeoVim 0.5 (not yet released) has built-in language server support. | 202 | NeoVim 0.5 (not yet released) has built-in language server support. |