mirror of
https://github.com/nix-community/nixvim.git
synced 2025-07-02 05:14:30 +02:00
modules/lsp: add per-server name
option
This allows users to override the name used for a given `lsp.servers.*` entry. The default is still the attr-name. This may be useful to inject raw lua, or to configure the same server in different ways via different attrs.
This commit is contained in:
parent
3722f88c5d
commit
29aa60b43a
2 changed files with 21 additions and 11 deletions
|
@ -1,4 +1,4 @@
|
|||
{ lib, ... }:
|
||||
{ lib, name, ... }:
|
||||
let
|
||||
inherit (lib) types;
|
||||
in
|
||||
|
@ -6,6 +6,15 @@ in
|
|||
options = {
|
||||
enable = lib.mkEnableOption "the language server";
|
||||
|
||||
name = lib.mkOption {
|
||||
type = types.maybeRaw types.str;
|
||||
description = ''
|
||||
The name of the language server, supplied to functions like `vim.lsp.enable()`.
|
||||
'';
|
||||
default = name;
|
||||
defaultText = lib.literalMD "the attribute name";
|
||||
};
|
||||
|
||||
activate = lib.mkOption {
|
||||
type = types.bool;
|
||||
description = ''
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue