zshrc: complete word from history with menu using ctrl-x ctrl-x
authorBernhard Tittelbach <bernhard@tittelbach.org>
Wed, 20 Jul 2011 16:47:04 +0000 (18:47 +0200)
committerMichael Prokop <mika@grml.org>
Thu, 21 Jul 2011 09:18:14 +0000 (11:18 +0200)
etc/zsh/zshrc

index 0977409..6fa7fcb 100644 (file)
@@ -960,6 +960,12 @@ zle -N jump_after_first_word
 
 bindkey '^x1' jump_after_first_word
 
+# complete word from history with menu (from Book: ZSH, OpenSource-Press)
+zle -C hist-complete complete-word _generic
+zstyle ':completion:hist-complete:*' completer _history
+#k# complete word from history with menu
+bindkey "^X^X" hist-complete
+
 # }}}
 
 # {{{ history