highlights for go
This commit is contained in:
parent
0a3fdd0682
commit
9a2666798a
2 changed files with 25 additions and 1 deletions
|
|
@ -35,7 +35,24 @@ nvim_lsp.rust_analyzer.setup({
|
|||
}
|
||||
}
|
||||
})
|
||||
nvim_lsp.gopls.setup({ on_attach = on_attach })
|
||||
nvim_lsp.gopls.setup({
|
||||
on_attach = function (client, bufnr)
|
||||
client.server_capabilities.semanticTokensProvider = {
|
||||
full = true,
|
||||
legend = {
|
||||
--tokenTypes = { 'namespace', 'type', 'class', 'enum', 'interface', 'struct', 'typeParameter', 'parameter', 'variable', 'property', 'enumMember', 'event', 'function', 'method', 'macro', 'keyword', 'modifier', 'comment', 'string', 'number', 'regexp', 'operator', 'decorator', },
|
||||
tokenTypes = { 'namespace' },
|
||||
tokenModifiers = { 'declaration', 'definition', 'readonly', 'static', 'deprecated', 'abstract', 'async', 'modification', 'documentation', 'defaultLibrary',
|
||||
},
|
||||
}
|
||||
}
|
||||
end,
|
||||
settings = {
|
||||
gopls = {
|
||||
semanticTokens = true,
|
||||
},
|
||||
},
|
||||
})
|
||||
nvim_lsp.pyright.setup({ on_attach = on_attach })
|
||||
|
||||
nvim_lsp.clangd.setup({ on_attach = on_attach })
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue