diff --git a/lua/lsp/protocol.lua b/lua/lsp/protocol.lua index 0ca66d4..1755ece 100644 --- a/lua/lsp/protocol.lua +++ b/lua/lsp/protocol.lua @@ -8,4 +8,18 @@ require("lspconfig").jsonls.setup({ require("lspconfig").taplo.setup({}) -require("lspconfig").yamlls.setup({}) +require("lspconfig").yamlls.setup({ + capabilities = capabilities, + settings = { + yaml = { + schemas = { + ["https://json.schemastore.org/golangci-lint.json"] = ".golangci.yaml", + ["https://json.schemastore.org/yamllint.json"] = ".protolint.yaml", + ["https://raw.githubusercontent.com/instrumenta/kubernetes-json-schema/master/v1.18.0-standalone-strict/all.json"] = "/*.k8s.yaml", + }, + schemaStore = { enable = true }, + format = { enable = true }, + completion = true, + }, + }, +})