mini/ai: init

This commit is contained in:
LilleAila 2025-01-17 18:57:59 +01:00
parent 9c09915170
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

@ -53,6 +53,8 @@
issue with setting the workspace directory. issue with setting the workspace directory.
- Add `vim.snippets.luasnip.setupOpts`, which was previously missing. - Add `vim.snippets.luasnip.setupOpts`, which was previously missing.
- Add `"prettierd"` as a formatter option in `vim.languages.markdown.format.type`. - Add `"prettierd"` as a formatter option in `vim.languages.markdown.format.type`.
- Add the following plugins from [mini.nvim](https://github.com/echasnovski/mini.nvim)
- `mini.ai`
[kaktu5](https://github.com/kaktu5): [kaktu5](https://github.com/kaktu5):

View file

@ -936,6 +936,22 @@
"type": "github" "type": "github"
} }
}, },
"plugin-mini-ai": {
"flake": false,
"locked": {
"lastModified": 1733662803,
"narHash": "sha256-b/776l9nYM9e2atzXrvOk9dCxjzIuW/+iINC/yPv88Y=",
"owner": "echasnovski",
"repo": "mini.ai",
"rev": "ebb04799794a7f94628153991e6334c3304961b8",
"type": "github"
},
"original": {
"owner": "echasnovski",
"repo": "mini.ai",
"type": "github"
}
},
"plugin-minimap-vim": { "plugin-minimap-vim": {
"flake": false, "flake": false,
"locked": { "locked": {
@ -2132,6 +2148,7 @@
"plugin-lz-n": "plugin-lz-n", "plugin-lz-n": "plugin-lz-n",
"plugin-lzn-auto-require": "plugin-lzn-auto-require", "plugin-lzn-auto-require": "plugin-lzn-auto-require",
"plugin-mind-nvim": "plugin-mind-nvim", "plugin-mind-nvim": "plugin-mind-nvim",
"plugin-mini-ai": "plugin-mini-ai",
"plugin-minimap-vim": "plugin-minimap-vim", "plugin-minimap-vim": "plugin-minimap-vim",
"plugin-modes-nvim": "plugin-modes-nvim", "plugin-modes-nvim": "plugin-modes-nvim",
"plugin-neo-tree-nvim": "plugin-neo-tree-nvim", "plugin-neo-tree-nvim": "plugin-neo-tree-nvim",

View file

@ -744,5 +744,11 @@
url = "github:stevearc/aerial.nvim"; url = "github:stevearc/aerial.nvim";
flake = false; flake = false;
}; };
# Mini.nvim
plugin-mini-ai = {
url = "github:echasnovski/mini.ai";
flake = false;
};
}; };
} }

View file

@ -27,6 +27,7 @@
"git" "git"
"languages" "languages"
"lsp" "lsp"
"mini"
"minimap" "minimap"
"notes" "notes"
"projects" "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
];
}