From 5c1be58f6d938ff93516d00cc3d2c0def4d80198 Mon Sep 17 00:00:00 2001 From: Mateusz Majewski Date: Sun, 19 Oct 2025 16:38:24 +0200 Subject: [PATCH] plugins/schemastore: use the correct LSP configuration keys for the new lsp module The old lsp module wrapped (in plugins/lsp/language-servers/default.nix) all configuration of the jsonls and yamlls servers in `json` and `yaml` keys respectively, so the schemastore module never needed to add those keys. However, the new lsp module passes the configuration as-is instead. This means that the schemastore module must be the one to wrap the configuration in the `json` and `yaml` keys. Without this, jsonls does not get its support enabled at all, and yamlls falls back to the built-in support. --- plugins/by-name/schemastore/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/plugins/by-name/schemastore/default.nix b/plugins/by-name/schemastore/default.nix index 96a7770c..cf4a9115 100644 --- a/plugins/by-name/schemastore/default.nix +++ b/plugins/by-name/schemastore/default.nix @@ -172,7 +172,7 @@ lib.nixvim.plugins.mkVimPlugin { }; lsp.servers = { - jsonls.config.settings = mkIf cfg.json.enable { + jsonls.config.settings.json = mkIf cfg.json.enable { schemas.__raw = '' require('schemastore').json.schemas(${lib.nixvim.toLuaObject cfg.json.settings}) ''; @@ -182,7 +182,7 @@ lib.nixvim.plugins.mkVimPlugin { validate.enable = mkDefault true; }; - yamlls.config.settings = mkIf cfg.yaml.enable { + yamlls.config.settings.yaml = mkIf cfg.yaml.enable { schemaStore = { # From the README: "You must disable built-in schemaStore support if you want to use # this plugin and its advanced options like `ignore`."