languages: add and move to mkServersOption

This commit is contained in:
poz 2025-07-21 10:53:09 +02:00
commit d47a771d19
No known key found for this signature in database
35 changed files with 89 additions and 224 deletions

View file

@ -9,6 +9,6 @@
in {
inherit (typesDag) dagOf;
inherit (typesPlugin) pluginsOpt extraPluginType mkPluginSetupOption luaInline pluginType borderType;
inherit (typesLanguage) diagnostics mkGrammarOption;
inherit (typesLanguage) diagnostics mkGrammarOption mkServersOption;
inherit (customTypes) char hexColor mergelessListOf;
}

View file

@ -32,6 +32,13 @@
mkPackageOption pkgs ["${grammar} treesitter"] {
default = ["vimPlugins" "nvim-treesitter" "builtGrammars" grammar];
};
mkServersOption = language: servers: defaultServers:
mkOption {
type = listOf (enum (attrNames servers));
default = defaultServers;
description = "${language} LSP servers to use";
};
in {
inherit diagnostics diagnosticSubmodule mkGrammarOption;
inherit diagnostics diagnosticSubmodule mkGrammarOption mkServersOption;
}