Initial commit
This commit is contained in:
47
home/editors/nvim/plugins/treesitter/textobjects.nix
Normal file
47
home/editors/nvim/plugins/treesitter/textobjects.nix
Normal file
@@ -0,0 +1,47 @@
|
||||
{
|
||||
enable = true;
|
||||
|
||||
settings = {
|
||||
select = {
|
||||
enable = true;
|
||||
lookahead = true;
|
||||
keymaps = {
|
||||
"af" = "@function.outer";
|
||||
"if" = "@function.inner";
|
||||
"ac" = "@class.outer";
|
||||
"ic" = "@class.inner";
|
||||
"a," = "@parameter.outer";
|
||||
"i," = "@parameter.inner";
|
||||
};
|
||||
};
|
||||
|
||||
move = {
|
||||
enable = true;
|
||||
setJumps = true;
|
||||
gotoNextStart = {
|
||||
"]f" = "@function.outer";
|
||||
"]c" = "@class.outer";
|
||||
"]," = "@parameter.inner";
|
||||
};
|
||||
gotoNextEnd = {
|
||||
"]F" = "@function.outer";
|
||||
"]C" = "@function.outer";
|
||||
};
|
||||
gotoPreviousStart = {
|
||||
"[f" = "@function.outer";
|
||||
"[c" = "@class.outer";
|
||||
"[," = "@parameter.inner";
|
||||
};
|
||||
gotoPreviousEnd = {
|
||||
"[F" = "@function.outer";
|
||||
"[C" = "@class.outer";
|
||||
};
|
||||
};
|
||||
|
||||
swap = {
|
||||
enable = true;
|
||||
swapNext = {">," = "@parameter.inner";};
|
||||
swapPrevious = {"<," = "@parameter.inner";};
|
||||
};
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user