plugins/sidekick: support non-bool settings.nes.enabled
This commit is contained in:
parent
24259c0f4f
commit
82a679abce
1 changed files with 2 additions and 1 deletions
|
|
@ -27,7 +27,8 @@ lib.nixvim.plugins.mkNeovimPlugin {
|
|||
extraConfig = cfg: {
|
||||
assertions = lib.nixvim.mkAssertions "plugins.sidekick" {
|
||||
assertion =
|
||||
(cfg.settings.nes.enabled or true)
|
||||
# Compare with false to handle settings.nes.enabled being a Lua function.
|
||||
(cfg.settings.nes.enabled or true != false)
|
||||
-> (config.plugins.copilot-lua.enable || config.lsp.servers.copilot.enable);
|
||||
message = "sidekick requires either copilot-lua (${options.plugins.copilot-lua.enable}) or copilot LSP (${options.lsp.servers}.copilot.enable) to be enabled when NES is enabled";
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue