From: Yegappan Lakshmanan Date: Thu, 18 Jan 2024 05:40:45 +0000 (-0800) Subject: Update instructions for using vim-plug to install the plugin X-Git-Url: http://www.git.stargrave.org/?a=commitdiff_plain;h=e3216cae9583c655bfb1c3cfac399738d0521621;p=vim-lsp.git Update instructions for using vim-plug to install the plugin --- diff --git a/README.md b/README.md index b2c8df1..ffedb69 100644 --- a/README.md +++ b/README.md @@ -45,6 +45,7 @@ The following language server protocol (LSP) features are supported: * Folding code * Inlay hints * Visually select symbol block/region +* Semantic Highlight ## Configuration @@ -157,6 +158,9 @@ call LspOptionsSet(#{ If you used [vim-plug](https://github.com/junegunn/vim-plug) to install the LSP plugin, then you need to use the VimEnter autocmd to initialize the LSP server and to set the LSP server options. For example: ```viml +let lspOpts = #{autoHighlightDiags: v:true} +autocmd VimEnter * call LspOptionsSet(lspOpts) + let lspServers = [#{ \ name: 'clang', \ filetype: ['c', 'cpp'], @@ -164,9 +168,6 @@ let lspServers = [#{ \ args: ['--background-index'] \ }] autocmd VimEnter * call LspAddServer(lspServers) - -let lspOpts = #{autoHighlightDiags: v:true} -autocmd VimEnter * call LspOptionsSet(lspOpts) ``` ## Supported Commands