languages/helm: fix yaml-language-server integration

This commit is contained in:
alfarel 2025-07-27 08:22:38 -04:00 committed by Ching Pei Yang
commit 671b6d187b
No known key found for this signature in database
GPG key ID: B3841364253DC4C8
2 changed files with 8 additions and 4 deletions

View file

@ -289,6 +289,8 @@
- Fix [blink.cmp] breaking when built-in sources were modified.
- Fix [conform.nvim] not allowing disabling formatting on and after save. Use
`null` value to disable them if conform is enabled.
- Fix Helm-YAML language module integration. YAML diagnostics will now remain in
`helmfile`s when both are enabled.
[TheColorman](https://github.com/TheColorman):

View file

@ -6,7 +6,7 @@
}: let
inherit (builtins) attrNames head;
inherit (lib.options) mkEnableOption mkOption;
inherit (lib.modules) mkIf mkMerge;
inherit (lib.modules) mkDefault mkIf mkMerge;
inherit (lib.meta) getExe;
inherit (lib.types) enum;
inherit (lib.nvim.types) mkGrammarOption singleOrListOf;
@ -27,11 +27,13 @@
dynamicRegistration = true;
};
};
settings = {
settings = mkIf (yamlCfg.enable && yamlCfg.lsp.enable) {
helm-ls = {
yamlls = {
# TODO: Determine if this is a good enough solution
path = (head yamlCfg.lsp.servers).cmd;
# Without this being enabled, the YAML language module will look broken in helmfiles
# if both modules are enabled at once.
enabled = mkDefault yamlCfg.lsp.enable;
path = head config.vim.lsp.servers.${head yamlCfg.lsp.servers}.cmd;
};
};
};