mini/align: init

This commit is contained in:
LilleAila 2025-01-17 19:00:43 +01:00
parent 8923d3b891
commit c8d727f2e9
No known key found for this signature in database
GPG key ID: D1ACCDCF2B9B9799
7 changed files with 62 additions and 0 deletions

View file

@ -55,6 +55,7 @@
- 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`
- `mini.align`
[kaktu5](https://github.com/kaktu5):

View file

@ -952,6 +952,22 @@
"type": "github"
}
},
"plugin-mini-align": {
"flake": false,
"locked": {
"lastModified": 1735582248,
"narHash": "sha256-oHub8dEihIx4kcP3CD9GXG1SUObJUVpH4bg2Z6PmadQ=",
"owner": "echasnovski",
"repo": "mini.align",
"rev": "e715137aece7d05734403d793b8b6b64486bc812",
"type": "github"
},
"original": {
"owner": "echasnovski",
"repo": "mini.align",
"type": "github"
}
},
"plugin-minimap-vim": {
"flake": false,
"locked": {
@ -2149,6 +2165,7 @@
"plugin-lzn-auto-require": "plugin-lzn-auto-require",
"plugin-mind-nvim": "plugin-mind-nvim",
"plugin-mini-ai": "plugin-mini-ai",
"plugin-mini-align": "plugin-mini-align",
"plugin-minimap-vim": "plugin-minimap-vim",
"plugin-modes-nvim": "plugin-modes-nvim",
"plugin-neo-tree-nvim": "plugin-neo-tree-nvim",

View file

@ -750,5 +750,10 @@
url = "github:echasnovski/mini.ai";
flake = false;
};
plugin-mini-align = {
url = "github:echasnovski/mini.align";
flake = false;
};
};
}

View file

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

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.align;
in {
vim = mkIf cfg.enable {
startPlugins = ["mini-align"];
pluginRC.mini-align = entryAnywhere ''
require("mini.align").setup(${toLuaObject cfg.setupOpts})
'';
};
}

View file

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

View file

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