parent
c9de5c5bd2
commit
3f4a38b5b5
@ -5,3 +5,6 @@ Applies correct bindkeys for input events.
|
|||||||
|
|
||||||
Without this module, you may experience oddities in how Zsh interprets input.
|
Without this module, you may experience oddities in how Zsh interprets input.
|
||||||
For example, using the UP key, then using the back arrow and pressing DELETE may capatalize characters rather than delete them.
|
For example, using the UP key, then using the back arrow and pressing DELETE may capatalize characters rather than delete them.
|
||||||
|
|
||||||
|
This module also provides double-dot parent directory expansion.
|
||||||
|
It can be enabled by uncommenting `zdouble_dot_expansion='true'` in your .zimrc
|
||||||
|
@ -65,6 +65,18 @@ if [[ -n "${key_info[Insert]}" ]]; then
|
|||||||
bindkey "${key_info[Insert]}" overwrite-mode
|
bindkey "${key_info[Insert]}" overwrite-mode
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if [[ ${zdouble_dot_expand} ]]; then
|
||||||
|
double-dot-expand() {
|
||||||
|
if [[ ${LBUFFER} == *.. ]]; then
|
||||||
|
LBUFFER+='/..'
|
||||||
|
else
|
||||||
|
LBUFFER+='.'
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
zle -N double-dot-expand
|
||||||
|
bindkey "." double-dot-expand
|
||||||
|
fi
|
||||||
|
|
||||||
bindkey "${key_info[Delete]}" delete-char
|
bindkey "${key_info[Delete]}" delete-char
|
||||||
bindkey "${key_info[Backspace]}" backward-delete-char
|
bindkey "${key_info[Backspace]}" backward-delete-char
|
||||||
|
|
||||||
|
@ -42,6 +42,14 @@ zprompt_theme='steeef'
|
|||||||
# See: http://zsh.sourceforge.net/Doc/Release/Options.html#Input_002fOutput
|
# See: http://zsh.sourceforge.net/Doc/Release/Options.html#Input_002fOutput
|
||||||
#zcorrection='true'
|
#zcorrection='true'
|
||||||
|
|
||||||
|
#
|
||||||
|
# Input
|
||||||
|
#
|
||||||
|
|
||||||
|
# Uncomment to enable double-dot expansion.
|
||||||
|
# This appends '../' to your input for each '.' you type after an initial '..'
|
||||||
|
#zdouble_dot_expand='true'
|
||||||
|
|
||||||
#
|
#
|
||||||
# Syntax-Highlighting
|
# Syntax-Highlighting
|
||||||
#
|
#
|
||||||
|
Reference in New Issue
Block a user