Skip to content

Commit

Permalink
[lsp] Add gopls config
Browse files Browse the repository at this point in the history
  • Loading branch information
talayhan committed Oct 8, 2024
1 parent 0f1d1bb commit 8a6e216
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions config/nvim/lua/lsp.lua
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,18 @@ require('lspconfig')['ts_ls'].setup {
settings = {}
}

require('lspconfig')['gopls'].setup {
settings = {
gopls = {
analyses = {
unusedparams = true,
},
staticcheck = true,
gofumpt = true,
},
},
}

vim.api.nvim_create_user_command("DiagnosticToggle", function()
local config = vim.diagnostic.config
local vt = config().virtual_text
Expand Down

0 comments on commit 8a6e216

Please sign in to comment.