mini/ai: init

This commit is contained in:
LilleAila 2025-01-17 18:57:59 +01:00
commit 8923d3b891
No known key found for this signature in database
GPG key ID: D1ACCDCF2B9B9799
8 changed files with 69 additions and 0 deletions

View file

@ -27,6 +27,7 @@
"git"
"languages"
"lsp"
"mini"
"minimap"
"notes"
"projects"

View file

@ -0,0 +1,13 @@
{
config,
lib,
...
}: let
inherit (lib.options) mkEnableOption mkOption;
inherit (lib.nvim.types) mkPluginSetupOption;
in {
options.vim.mini.ai = {
enable = mkEnableOption "mini.ai";
setupOpts = mkPluginSetupOption "mini.ai" {};
};
}

View file

@ -0,0 +1,19 @@
{
config,
lib,
...
}: let
inherit (lib.modules) mkIf;
inherit (lib.nvim.dag) entryAnywhere;
inherit (lib.nvim.lua) toLuaObject;
cfg = config.vim.mini.ai;
in {
vim = mkIf cfg.enable {
startPlugins = ["mini-ai"];
pluginRC.mini-ai = entryAnywhere ''
require("mini.ai").setup(${toLuaObject cfg.setupOpts})
'';
};
}

View file

@ -0,0 +1,6 @@
{
imports = [
./ai.nix
./config.nix
];
}

View file

@ -0,0 +1,5 @@
{
imports = [
./ai
];
}