diff --git a/nvim/lua/plugins/lsp.lua b/nvim/lua/plugins/lsp.lua index c3532e2..221194f 100644 --- a/nvim/lua/plugins/lsp.lua +++ b/nvim/lua/plugins/lsp.lua @@ -48,34 +48,31 @@ local servers_config = { return { settings = { gopls = { + -- build buildFlags = buildFlags, + -- formatting + gofumpt = true, + -- ui codelenses = { - tidy = true, - vendor = true, - generate = true, - regenerate_cgo = true, - upgrade_dependency = true, gc_details = true, test = true, - run_vulncheck_exp = true, + run_govulncheck = true, }, + semanticTokens = true, + -- completion + usePlaceholders = true, + -- diagnostic analyses = { useany = true, - nilness = true, - unusedparams = true, unusedvariable = true, - unusedwrite = true, shadow = true, }, - semanticTokens = true, - gofumpt = true, staticcheck = true, - importShortcut = 'Both', - completionDocumentation = true, - linksInHover = true, - usePlaceholders = true, - experimentalPostfixCompletions = true, + vulncheck = 'Imports', + -- documentation hoverKind = 'FullDocumentation', + linksInHover = true, + -- inlay hints hints = { assignVariableTypes = true, compositeLiteralFields = true, @@ -85,6 +82,8 @@ local servers_config = { parameterNames = true, rangeVariableTypes = true, }, + -- navigation + importShortcut = 'Both', }, tags = { skipUnexported = true }, }, @@ -205,7 +204,7 @@ return { return end return { - timeout_ms = 1000, + timeout_ms = 5000, lsp_fallback = true, } end,