We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3888522 commit 6348336Copy full SHA for 6348336
modules/default.nix
@@ -16,6 +16,7 @@
16
./filetype.nix
17
./highlights.nix
18
./keymaps.nix
19
+ ./lazyload.nix
20
./lua-loader.nix
21
./opts.nix
22
./output.nix
modules/lazyload.nix
@@ -0,0 +1,30 @@
1
+{
2
+ config,
3
+ lib,
4
+ ...
5
+}:
6
+let
7
+ implementations = [
8
+ "lz-n"
9
+ "lazy"
10
+ ];
11
+in
12
13
+ config = {
14
+ assertions =
15
+ let
+ enabled = builtins.filter (x: config.plugins.${x}.enable) implementations;
+ count = builtins.length enabled;
+ in
+ [
+ {
+ assertion = count < 2;
+ message = ''
23
+ You have multiple lazy-loaders enabled:
24
+ ${lib.concatImapStringsSep "\n" (i: x: "${toString i}. plugins.${x}") enabled}
25
+ Please ensure only one is enabled at a time.
26
+ '';
27
+ }
28
29
+ };
30
+}
0 commit comments