]> Sergey Matveev's repositories - vim-lsp.git/commitdiff
Update instructions for using vim-plug to install the plugin
authorYegappan Lakshmanan <yegappan@yahoo.com>
Thu, 18 Jan 2024 05:40:45 +0000 (21:40 -0800)
committerYegappan Lakshmanan <yegappan@yahoo.com>
Thu, 18 Jan 2024 05:40:45 +0000 (21:40 -0800)
README.md

index b2c8df1ae715e6183ad9b4690abada9c09895ec8..ffedb69aa0ed084003c9d6e5724dc90b9cf7d11f 100644 (file)
--- 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