mirror of
https://github.com/nix-community/nixvim.git
synced 2025-06-21 16:39:00 +02:00
plugins/lsp/efmls-configs: simplify implementation
This commit is contained in:
parent
c0a4c2ef6f
commit
4b05fde873
1 changed files with 2 additions and 3 deletions
|
@ -214,7 +214,6 @@ in
|
||||||
config =
|
config =
|
||||||
let
|
let
|
||||||
cfg = config.plugins.efmls-configs;
|
cfg = config.plugins.efmls-configs;
|
||||||
toolAsList = tools: if isList tools then tools else [ tools ];
|
|
||||||
|
|
||||||
# Tools that have been selected by the user
|
# Tools that have been selected by the user
|
||||||
tools = lists.unique (
|
tools = lists.unique (
|
||||||
|
@ -225,7 +224,7 @@ in
|
||||||
linter ? [ ],
|
linter ? [ ],
|
||||||
formatter ? [ ],
|
formatter ? [ ],
|
||||||
}:
|
}:
|
||||||
(toolAsList linter) ++ (toolAsList formatter)
|
(toList linter) ++ (toList formatter)
|
||||||
) (attrValues cfg.setup)
|
) (attrValues cfg.setup)
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
@ -251,7 +250,7 @@ in
|
||||||
kind: opt:
|
kind: opt:
|
||||||
map (
|
map (
|
||||||
tool: if isString tool then helpers.mkRaw "require 'efmls-configs.${kind}.${tool}'" else tool
|
tool: if isString tool then helpers.mkRaw "require 'efmls-configs.${kind}.${tool}'" else tool
|
||||||
) (toolAsList opt);
|
) (toList opt);
|
||||||
|
|
||||||
setupOptions =
|
setupOptions =
|
||||||
(mapAttrs (
|
(mapAttrs (
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue