chiark / gitweb /
dot/zshrc: Inhibit line editing when terminal is `dumb'.
[profile] / dot / zshrc
index 736b37447839fe872b79d3b4463b99d668bd71de..4dc0fb7b531ac0e563484f82c7c6b69665ec6e06 100644 (file)
--- a/dot/zshrc
+++ b/dot/zshrc
@@ -30,6 +30,8 @@ fi
 ###--------------------------------------------------------------------------
 ### Line editing.
 
+case $TERM in dumb) unsetopt zle ;; esac
+
 bindkey -e
 
 for w in \
@@ -59,8 +61,8 @@ bindkey "\et" transpose-words-bash
 bindkey "\e^t" transpose-words-shell
 bindkey "\eu" up-case-word-bash
 bindkey "\e^u" up-case-word-shell
-bindkey "\el" up-case-word-bash
-bindkey "\e^l" up-case-word-shell
+bindkey "\el" down-case-word-bash
+bindkey "\e^l" down-case-word-shell
 bindkey "\ec" capitalize-word-bash
 bindkey "\e^c" capitalize-word-shell
 
@@ -84,14 +86,9 @@ __mdw_just_one_space () {
 zle -N just-one-space __mdw_just_one_space
 bindkey "\e " just-one-space
 
-
 ###--------------------------------------------------------------------------
 ### Completion.
 
-## Initialize the fancy completion machinery.
-autoload -Uz compinit
-compinit
-
 ## Contexts: :completion:FUNCTION:COMPLETER:COMMAND:ARGUMENT:TAG
 zstyle ':completion:*' completer _expand _complete _ignored _approximate
 zstyle ':completion:*' insert-unambiguous false
@@ -103,6 +100,10 @@ zstyle ':completion:*' original true
 zstyle ':completion:*' verbose false
 zstyle ':completion:*:*:git*:*' verbose true
 
+## Initialize the fancy completion machinery.
+autoload -Uz compinit
+compinit
+
 _r () { words[1]=sudo; _normal; }
 compdef _r rootly
 compdef _ssh @