From 51401c41033e886ad6ddf29e67b6262660a96e85 Mon Sep 17 00:00:00 2001 From: KoenDR06 Date: Wed, 10 Sep 2025 22:22:22 +0200 Subject: [PATCH] add helix macros for deleting and changing --- modules/apps/terminal/helix.nix | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/modules/apps/terminal/helix.nix b/modules/apps/terminal/helix.nix index 1c6f0c7..1a09520 100644 --- a/modules/apps/terminal/helix.nix +++ b/modules/apps/terminal/helix.nix @@ -21,14 +21,18 @@ right = ["diagnostics" "selections" "register" "file-encoding" "position" "position-percentage"]; }; }; - keys = { + keys = let + reg = ""; + deleteMacro = "@\"${reg}y"; + changeMacro = "@\"${reg}yi"; + in { normal = { - "d" = "delete_selection_noyank"; - "A-d" = "delete_selection"; + c = changeMacro; + d = deleteMacro; }; select = { - "d" = "delete_selection_noyank"; - "A-d" = "delete_selection"; + c = changeMacro; + d = deleteMacro; }; }; };