mirror of
https://github.com/nix-community/nixvim.git
synced 2025-07-08 08:14:33 +02:00
plugins/telescope.extensions.undo: init + (#654)
* new plugin * add content * add content * Update plugins/telescope/undo.nix Co-authored-by: Gaétan Lepage <33058747+GaetanLepage@users.noreply.github.com> * Update plugins/telescope/undo.nix Co-authored-by: Gaétan Lepage <33058747+GaetanLepage@users.noreply.github.com> * add test * Update plugins/telescope/undo.nix Co-authored-by: Gaétan Lepage <33058747+GaetanLepage@users.noreply.github.com> * fix per pr comments * fix per pr comments * fix per pr comments --------- Co-authored-by: Haseeb Majid <haseeb.majid@imaginecurve.com> Co-authored-by: Gaétan Lepage <33058747+GaetanLepage@users.noreply.github.com>
This commit is contained in:
parent
0c5dcb56d1
commit
520a59668d
3 changed files with 172 additions and 0 deletions
34
tests/test-sources/plugins/telescope/undo.nix
Normal file
34
tests/test-sources/plugins/telescope/undo.nix
Normal file
|
@ -0,0 +1,34 @@
|
|||
{
|
||||
empty = {
|
||||
plugins.telescope.enable = true;
|
||||
};
|
||||
|
||||
example = {
|
||||
plugins.telescope = {
|
||||
enable = true;
|
||||
|
||||
extensions.undo = {
|
||||
enable = true;
|
||||
|
||||
useDelta = true;
|
||||
useCustomCommand = ["bash" "-c" "echo '$DIFF' | delta"];
|
||||
sideBySide = true;
|
||||
diffContextLines = 8;
|
||||
entryFormat = "state #$ID";
|
||||
timeFormat = "!%Y-%m-%dT%TZ";
|
||||
mappings = {
|
||||
i = {
|
||||
"<cr>" = "yank_additions";
|
||||
"<s-cr>" = "yank_deletions";
|
||||
"<c-cr>" = "restore";
|
||||
};
|
||||
n = {
|
||||
"y" = "yank_additions";
|
||||
"Y" = "yank_deletions";
|
||||
"u" = "restore";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue