Просмотр исходного кода

Add command line editing to zsh

This is default functionality in bash that is interesting to have back
in zsh. This will be put in to test if getting used to using it turns
out to be good practice.

Revert this commit if not.
Weiyi Lou 10 лет назад
Родитель
Сommit
2d4db83d7a
1 измененных файлов с 5 добавлено и 0 удалено
  1. 5 0
      zsh/custom/lib/key-bindings.zsh

+ 5 - 0
zsh/custom/lib/key-bindings.zsh

@@ -65,3 +65,8 @@ bindkey '^Z' fancy-ctrl-z
 
 # <S-Tab> to tab backwards through autocomplete suggestions.
 bindkey '^[[Z' reverse-menu-complete
+
+# Toggle Command Line Editing with <C-x><C-e>, like bash.
+autoload -U edit-command-line
+zle -N edit-command-line
+bindkey '\C-x\C-e' edit-command-line