mirror of
https://github.com/nix-community/nixvim.git
synced 2025-06-21 00:25:42 +02:00
plugins/efmls: package option defaultText should not depend on pkgs
The `defaultText` was conditional on default. Specifically, `default.meta.platforms`. This is not good, because it means the package must be evaluated in order to build the docs.
This commit is contained in:
parent
09733a5539
commit
88652ce69a
1 changed files with 7 additions and 4 deletions
|
@ -44,10 +44,13 @@ in
|
|||
# Filter package defaults that are not compatible with the current platform
|
||||
(lib.attrsets.mapAttrs (
|
||||
_: opt:
|
||||
if lib.meta.availableOn pkgs.stdenv.hostPlatform opt.default then
|
||||
opt
|
||||
else
|
||||
builtins.removeAttrs opt [ "defaultText" ] // { default = null; }
|
||||
opt
|
||||
// {
|
||||
default = if lib.meta.availableOn pkgs.stdenv.hostPlatform opt.default then opt.default else null;
|
||||
defaultText = lib.literalMD ''
|
||||
`${opt.defaultText.text}` if available on the current system, otherwise null
|
||||
'';
|
||||
}
|
||||
))
|
||||
];
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue