mirror of
https://github.com/nix-community/nixvim.git
synced 2025-11-09 03:56:05 +01:00
modules/lsp: be explicit about shorthandOnlyDefinesConfig
`shorthandOnlyDefinesConfig` is true by default for `lib.types.submodule`, and false by default for `lib.types.submoduleWith` and `lib.evalModules`. Since we rely on it for our `lsp.servers.*.config` option, let's enable it explicitly.
This commit is contained in:
parent
9f336d2d71
commit
cf6c8ef1fa
1 changed files with 8 additions and 1 deletions
|
|
@ -19,7 +19,14 @@ let
|
||||||
# Create a submodule type from `server.nix`
|
# Create a submodule type from `server.nix`
|
||||||
# Used as the type for both the freeform `lsp.servers.<name>`
|
# Used as the type for both the freeform `lsp.servers.<name>`
|
||||||
# and the explicitly declared `lsp.servers.*` options
|
# and the explicitly declared `lsp.servers.*` options
|
||||||
mkServerType = args: types.submodule (mkServerModule args);
|
mkServerType =
|
||||||
|
args:
|
||||||
|
types.submoduleWith {
|
||||||
|
# Server modules have a `config` option, so we must use
|
||||||
|
# shorthandOnlyDefinesConfig to avoid confusing the module system.
|
||||||
|
shorthandOnlyDefinesConfig = true;
|
||||||
|
modules = [ (mkServerModule args) ];
|
||||||
|
};
|
||||||
|
|
||||||
# Create a server option
|
# Create a server option
|
||||||
# Used below for the `lsp.servers.*` options
|
# Used below for the `lsp.servers.*` options
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue