Merge pull request #1110 from derethil/fix/lazy-plugin-enabled

[skip ci] lazy: enabled option accepts luaInline instead of str

skip ci for unrelated formatter changes
This commit is contained in:
Ching Pei Yang 2025-08-27 12:04:23 +02:00 committed by GitHub
commit 34e42a6186
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 6 additions and 2 deletions

View file

@ -523,3 +523,7 @@
[diced](https://github.com/diced):
- Fixed `typescript` treesitter grammar not being included by default.
[derethil](https://github.com/derethil):
- Fix `vim.lazy.plugins.<name>.enabled` Lua evaluation.

View file

@ -1,7 +1,7 @@
{lib, ...}: let
inherit (lib.options) mkOption mkEnableOption;
inherit (lib.types) enum listOf submodule nullOr str bool int attrsOf anything either oneOf lines;
inherit (lib.nvim.types) pluginType;
inherit (lib.nvim.types) pluginType luaInline;
inherit (lib.nvim.config) mkBool;
lznKeysSpec = submodule {
@ -98,7 +98,7 @@
# lz.n options
enabled = mkOption {
type = nullOr (either bool str);
type = nullOr (either bool luaInline);
default = null;
description = "When false, or if the lua function returns false, this plugin will not be included in the spec";
};