neovim-flake/modules/plugins/ui/modes/config.nix

22 lines
382 B
Nix
Raw Permalink Normal View History

2023-04-03 11:12:05 +02:00
{
config,
lib,
...
}: let
inherit (lib.modules) mkIf;
inherit (lib.nvim.dag) entryAnywhere;
2024-03-10 20:02:04 +01:00
inherit (lib.nvim.lua) toLuaObject;
2023-04-03 11:12:05 +02:00
cfg = config.vim.ui.modes-nvim;
in {
config = mkIf cfg.enable {
vim.startPlugins = [
"modes-nvim"
];
vim.pluginRC.modes-nvim = entryAnywhere ''
2024-03-10 20:02:04 +01:00
require('modes').setup(${toLuaObject cfg.setupOpts})
2023-04-03 11:12:05 +02:00
'';
};
}