refactor(nvim)!: add opts option
This commit is contained in:
parent
12a5420ee9
commit
6a125a1df6
27 changed files with 273 additions and 238 deletions
31
modules/programs/nvim/plugins/lua/null-ls-nvim.lua
Normal file
31
modules/programs/nvim/plugins/lua/null-ls-nvim.lua
Normal file
|
|
@ -0,0 +1,31 @@
|
|||
local null_ls = require("null-ls")
|
||||
|
||||
null_ls.setup({
|
||||
sources = {
|
||||
-- Code actions
|
||||
null_ls.builtins.code_actions.shellcheck,
|
||||
null_ls.builtins.code_actions.statix,
|
||||
-- Completion
|
||||
null_ls.builtins.completion.spell,
|
||||
-- Diagnostics
|
||||
null_ls.builtins.diagnostics.deadnix,
|
||||
null_ls.builtins.diagnostics.shellcheck,
|
||||
null_ls.builtins.diagnostics.statix,
|
||||
},
|
||||
})
|
||||
|
||||
-- disable (c)spell initially
|
||||
null_ls.disable("spell")
|
||||
|
||||
-- make sources toggle able
|
||||
require("which-key").register({
|
||||
n = {
|
||||
name = "null-ls",
|
||||
s = {
|
||||
function()
|
||||
null_ls.toggle("spell")
|
||||
end,
|
||||
"spell",
|
||||
},
|
||||
},
|
||||
}, { prefix = "<leader>t" })
|
||||
Loading…
Add table
Add a link
Reference in a new issue