diff --git a/chezmoi/private_dot_config/nvim/init.lua b/chezmoi/private_dot_config/nvim/init.lua index 7ff977b..e025467 100644 --- a/chezmoi/private_dot_config/nvim/init.lua +++ b/chezmoi/private_dot_config/nvim/init.lua @@ -303,6 +303,15 @@ later(function() -- provides nice "diagnostics" output source = 'folke/trouble.nvim' }) + add({ + -- hook up linters + source = 'nvimtools/none-ls.nvim', + depends = { + { + source = 'nvim-lua/plenary.nvim' + } + } + }) -- only perform these mappings if an LSP is attached local on_attach = function(client, buffnr) @@ -345,6 +354,16 @@ later(function() }) end + -- TODO see if there is a way to automatically do this rather than having to manually specify them + local null_ls = require('null-ls') + null_ls.setup({ + -- enable debug if you want to be able to debug null_ls settings + -- debug = true, + sources = { + null_ls.builtins.diagnostics.golangci_lint, + }, + }) + require('trouble').setup() vim.keymap.set('n', 'xx', 'Trouble diagnostics toggle', { noremap = true, silent = true }) diff --git a/chezmoi/private_dot_config/nvim/mini-deps-snap b/chezmoi/private_dot_config/nvim/mini-deps-snap index 8ae0721..276f85b 100644 --- a/chezmoi/private_dot_config/nvim/mini-deps-snap +++ b/chezmoi/private_dot_config/nvim/mini-deps-snap @@ -7,9 +7,11 @@ return { ["mason-lspconfig.nvim"] = "25c11854aa25558ee6c03432edfa0df0217324be", ["mason.nvim"] = "e2f7f9044ec30067bc11800a9e266664b88cda22", ["mini.nvim"] = "848c5e8f428faf843051768e0d56104cd02aea1f", + ["none-ls.nvim"] = "0e0a940477cc08fa7b1799384a1d668058ed4e61", ["nvim-lsp-basics"] = "632714bd3ab355eb6e725b5a78cd8730f12d14d2", ["nvim-lspconfig"] = "0678aa439b82965daf03679cd146e84f10e299c3", ["nvim-treesitter"] = "d1e1f17cea23f14cbe230635b9bb654a835f02d7", + ["plenary.nvim"] = "2d9b06177a975543726ce5c73fca176cedbffe9d", ["trouble.nvim"] = "6efc446226679fda0547c0fd6a7892fd5f5b15d8", ["vim-fugitive"] = "d4877e54cef67f5af4f950935b1ade19ed6b7370", ["vim-surround"] = "3d188ed2113431cf8dac77be61b842acb64433d9",