zshrc: keybinding Alt-Delete kills current/right word
authorBernhard Tittelbach <bernhard@tittelbach.org>
Wed, 20 Jul 2011 17:13:45 +0000 (19:13 +0200)
committerMichael Prokop <mika@grml.org>
Thu, 21 Jul 2011 09:42:24 +0000 (11:42 +0200)
etc/zsh/zshrc

index 6fa7fcb..2e7e65a 100644 (file)
@@ -569,6 +569,11 @@ bindkey '\e[4~' end-of-line             # end
 bindkey '\e[A'  up-line-or-search       # cursor up
 bindkey '\e[B'  down-line-or-search     # <ESC>-
 
+## alt-backspace is already the default for backwards-delete-word
+## let's also set alt-delete for deleting current word (right of cursor)
+#k# Delete current word
+bindkey "3~" delete-word
+
 bindkey '^xp'   history-beginning-search-backward
 bindkey '^xP'   history-beginning-search-forward
 # bindkey -s '^L' "|less\n"             # ctrl-L pipes to less