Dotfiles_nvim/lua/toolchain/scripts.lua

27 lines
734 B
Lua
Raw Permalink Normal View History

2024-09-07 18:39:22 +00:00
local T = require('toolchain')
local M = {}
2024-09-07 23:50:39 +00:00
function M.setup()
2024-09-07 18:39:22 +00:00
T.add_highlighter_autoinstalls('bash', 'dockerfile', 'make', 'just')
T.add_null_ls_module(function(null_ls)
return {
-- Diagnostics
null_ls.builtins.diagnostics.actionlint,
null_ls.builtins.diagnostics.checkmake,
null_ls.builtins.diagnostics.dotenv_linter,
-- Formatter
null_ls.builtins.formatting.shfmt,
null_ls.builtins.formatting.shellharden,
}
end)
T.add_lsp_autoinstalls('bashls')
T.add_lsps(function(lspconfig, capabilities)
local config = { capabilities = capabilities }
lspconfig.bashls.setup(config)
end)
end
return M