about summary refs log tree commit diff
path: root/hosts
diff options
context:
space:
mode:
authorBaitinq <[email protected]>2022-06-19 16:41:53 +0200
committerBaitinq <[email protected]>2022-06-19 16:41:53 +0200
commit0b3fff4fd703a71c245842a2e91f81bcd4a8d172 (patch)
tree1e34540e58b331d8309ec99235d36e4aec324de3 /hosts
parentfmt (diff)
downloadnixos-config-0b3fff4fd703a71c245842a2e91f81bcd4a8d172.tar.gz
nixos-config-0b3fff4fd703a71c245842a2e91f81bcd4a8d172.tar.bz2
nixos-config-0b3fff4fd703a71c245842a2e91f81bcd4a8d172.zip
Change zsh config to fix up history
Diffstat (limited to 'hosts')
-rw-r--r--hosts/home.nix10
1 files changed, 6 insertions, 4 deletions
diff --git a/hosts/home.nix b/hosts/home.nix
index c581863..96ab3c7 100644
--- a/hosts/home.nix
+++ b/hosts/home.nix
@@ -128,17 +128,19 @@ in
       };
 
       initExtra = ''
+        autoload -U history-search-end #needed for -end
+        zle -N history-beginning-search-backward-end history-search-end
+        zle -N history-beginning-search-forward-end history-search-end
+
         #when going up go up only beggining of curr word history
-        bindkey '\e[A' history-search-backward
-        bindkey '\e[B' history-search-forward
+        bindkey '\e[A' history-beginning-search-backward-end
+        bindkey '\e[B' history-beginning-search-forward-end
         #ctrl + arrow forward/backward word
         bindkey "^[[1;5C" forward-word
         bindkey "^[[1;5D" backward-word
         #alt + arrow forward/backward word
         bindkey "^[[1;3C" forward-word
         bindkey "^[[1;3D" backward-word
-        #ctrl + delete delete whole word
-        bindkey '^H' backward-kill-word
         #alt + delete delete whole word
         bindkey "\e\x7f" backward-kill-word
       '';