mirror of
https://github.com/nix-community/nixvim.git
synced 2025-11-08 19:46:06 +01:00
plugins/mini-snippets: init
This commit is contained in:
parent
e948015920
commit
acbb512494
2 changed files with 54 additions and 0 deletions
25
plugins/by-name/mini-snippets/default.nix
Normal file
25
plugins/by-name/mini-snippets/default.nix
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
{ lib, ... }:
|
||||
lib.nixvim.plugins.mkNeovimPlugin {
|
||||
name = "mini-snippets";
|
||||
moduleName = "mini.snippets";
|
||||
|
||||
maintainers = [ lib.maintainers.HeitorAugustoLN ];
|
||||
|
||||
settingsExample = {
|
||||
snippets = lib.nixvim.nestedLiteral (lib.literalExpression "lib.nixvim.emptyTable");
|
||||
|
||||
mappings = {
|
||||
expand = "<C-j>";
|
||||
jump_next = "<C-l>";
|
||||
jump_prev = "<C-h>";
|
||||
stop = "<C-c>";
|
||||
};
|
||||
|
||||
expand = {
|
||||
prepare = lib.nixvim.nestedLiteralLua "nil";
|
||||
match = lib.nixvim.nestedLiteralLua "nil";
|
||||
select = lib.nixvim.nestedLiteralLua "nil";
|
||||
insert = lib.nixvim.nestedLiteralLua "nil";
|
||||
};
|
||||
};
|
||||
}
|
||||
29
tests/test-sources/plugins/by-name/mini-snippets/default.nix
Normal file
29
tests/test-sources/plugins/by-name/mini-snippets/default.nix
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
{ lib, ... }:
|
||||
{
|
||||
empty = {
|
||||
plugins.mini-snippets.enable = true;
|
||||
};
|
||||
|
||||
defaults = {
|
||||
plugins.mini-snippets = {
|
||||
enable = true;
|
||||
settings = {
|
||||
snippets = lib.nixvim.emptyTable;
|
||||
|
||||
mappings = {
|
||||
expand = "<C-j>";
|
||||
jump_next = "<C-l>";
|
||||
jump_prev = "<C-h>";
|
||||
stop = "<C-c>";
|
||||
};
|
||||
|
||||
expand = {
|
||||
prepare = lib.nixvim.mkRaw "nil";
|
||||
match = lib.nixvim.mkRaw "nil";
|
||||
select = lib.nixvim.mkRaw "nil";
|
||||
insert = lib.nixvim.mkRaw "nil";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue