mirror of
https://github.com/nix-community/nixvim.git
synced 2025-11-08 11:36:07 +01:00
plugins/treesitter-textobjects: migrate to mkNeovimPlugin
This commit is contained in:
parent
593e8114cd
commit
af57bad10d
4 changed files with 191 additions and 311 deletions
|
|
@ -12,71 +12,73 @@
|
|||
treesitter-textobjects = {
|
||||
enable = true;
|
||||
|
||||
select = {
|
||||
enable = true;
|
||||
disable = [ ];
|
||||
lookahead = true;
|
||||
keymaps = {
|
||||
af = "@function.outer";
|
||||
"if" = "@function.inner";
|
||||
ac = "@class.outer";
|
||||
ic = {
|
||||
query = "@class.inner";
|
||||
desc = "Select inner part of a class region";
|
||||
settings = {
|
||||
select = {
|
||||
enable = true;
|
||||
disable = [ ];
|
||||
lookahead = true;
|
||||
keymaps = {
|
||||
af = "@function.outer";
|
||||
"if" = "@function.inner";
|
||||
ac = "@class.outer";
|
||||
ic = {
|
||||
query = "@class.inner";
|
||||
desc = "Select inner part of a class region";
|
||||
};
|
||||
};
|
||||
selection_modes = {
|
||||
"@parameter.outer" = "v";
|
||||
"@function.outer" = "V";
|
||||
"@class.outer" = "<c-v>";
|
||||
};
|
||||
include_surrounding_whitespace = true;
|
||||
};
|
||||
swap = {
|
||||
enable = true;
|
||||
disable = [ ];
|
||||
swap_next = {
|
||||
"<leader>a" = "@parameter.inner";
|
||||
};
|
||||
swap_previous = {
|
||||
"<leader>A" = "@parameter.inner";
|
||||
};
|
||||
};
|
||||
selectionModes = {
|
||||
"@parameter.outer" = "v";
|
||||
"@function.outer" = "V";
|
||||
"@class.outer" = "<c-v>";
|
||||
move = {
|
||||
enable = true;
|
||||
disable = [ ];
|
||||
set_jumps = true;
|
||||
goto_next_start = {
|
||||
"]m" = "@function.outer";
|
||||
"]]" = "@class.outer";
|
||||
};
|
||||
goto_next_end = {
|
||||
"]M" = "@function.outer";
|
||||
"][" = "@class.outer";
|
||||
};
|
||||
goto_previous_start = {
|
||||
"[m" = "@function.outer";
|
||||
"[[" = "@class.outer";
|
||||
};
|
||||
goto_previous_end = {
|
||||
"[M" = "@function.outer";
|
||||
"[]" = "@class.outer";
|
||||
};
|
||||
goto_next = {
|
||||
"]d" = "@conditional.outer";
|
||||
};
|
||||
goto_previous = {
|
||||
"[d" = "@conditional.outer";
|
||||
};
|
||||
};
|
||||
includeSurroundingWhitespace = true;
|
||||
};
|
||||
swap = {
|
||||
enable = true;
|
||||
disable = [ ];
|
||||
swapNext = {
|
||||
"<leader>a" = "@parameter.inner";
|
||||
lsp_interop = {
|
||||
enable = true;
|
||||
border = "none";
|
||||
peek_definition_code = {
|
||||
"<leader>df" = "@function.outer";
|
||||
"<leader>dF" = "@class.outer";
|
||||
};
|
||||
floating_preview_opts = { };
|
||||
};
|
||||
swapPrevious = {
|
||||
"<leader>A" = "@parameter.inner";
|
||||
};
|
||||
};
|
||||
move = {
|
||||
enable = true;
|
||||
disable = [ ];
|
||||
setJumps = true;
|
||||
gotoNextStart = {
|
||||
"]m" = "@function.outer";
|
||||
"]]" = "@class.outer";
|
||||
};
|
||||
gotoNextEnd = {
|
||||
"]M" = "@function.outer";
|
||||
"][" = "@class.outer";
|
||||
};
|
||||
gotoPreviousStart = {
|
||||
"[m" = "@function.outer";
|
||||
"[[" = "@class.outer";
|
||||
};
|
||||
gotoPreviousEnd = {
|
||||
"[M" = "@function.outer";
|
||||
"[]" = "@class.outer";
|
||||
};
|
||||
gotoNext = {
|
||||
"]d" = "@conditional.outer";
|
||||
};
|
||||
gotoPrevious = {
|
||||
"[d" = "@conditional.outer";
|
||||
};
|
||||
};
|
||||
lspInterop = {
|
||||
enable = true;
|
||||
border = "none";
|
||||
peekDefinitionCode = {
|
||||
"<leader>df" = "@function.outer";
|
||||
"<leader>dF" = "@class.outer";
|
||||
};
|
||||
floatingPreviewOpts = { };
|
||||
};
|
||||
};
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue