enc: add default config golang

This commit is contained in:
asep.komarudin 2024-06-22 12:01:30 +07:00
parent abb9a69a87
commit 178c969312
6 changed files with 161 additions and 192 deletions

View file

@ -40,7 +40,9 @@ if pcode.active_javascript_config.status then
for _, ts in pairs(lst_ts) do
table.insert(pcode.treesitter_ensure_installed, ts)
end
table.insert(pcode.mason_ensure_installed, "tsserver")
for _, lsp in pairs({ "html", "cssls", "emmet_ls", "eslint", "jsonls", "tsserver" }) do
table.insert(pcode.mason_ensure_installed, lsp)
end
end
-- run if php config true
if pcode.active_php_config then
@ -52,4 +54,14 @@ if pcode.active_php_config then
table.insert(pcode.null_ls_ensure_installed, "phpcbf")
table.insert(pcode.null_ls_ensure_installed, "phpcs")
end
-- run if golang config true
if pcode.active_golang_config then
local lst_ts = { "go", "gomod", "gosum", "gotmpl", "gowork" }
for _, ts in pairs(lst_ts) do
table.insert(pcode.treesitter_ensure_installed, ts)
end
table.insert(pcode.mason_ensure_installed, "gopls")
table.insert(pcode.null_ls_ensure_installed, "ast_grep")
table.insert(pcode.null_ls_ensure_installed, "gofumpt")
end
return {}