This commit is contained in:
hl 2024-11-15 22:51:18 +08:00
parent 6ac3c5a641
commit 0f0aa768fb

11
.zshrc
View File

@ -11,8 +11,11 @@ setopt HIST_IGNORE_SPACE
zshaddhistory() { whence ${${(z)1}[1]} >| /dev/null || return 1 }
unsetopt beep
# cat > /dev/null test keys
# zle -al list all commands
# To test keys:
# cat > /dev/null
# sed -n l
# List all commands:
# zle -al
bindkey -e #emacs
bindkey "^[[3~" delete-char #Delete
bindkey "^[[H" beginning-of-line #Home
@ -29,9 +32,11 @@ source /usr/share/zsh-autosuggestions/zsh-autosuggestions.zsh
source /usr/share/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh
source /usr/share/zsh-autocomplete/zsh-autocomplete.plugin.zsh
# Tab
bindkey "^I" menu-select
bindkey -M menuselect "^I" menu-complete
bindkey -M menuselect "$terminfo[kcbt]" reverse-menu-complete
# Shift + Tab
bindkey -M menuselect "^[[Z" reverse-menu-complete
bindkey -M menuselect "^A" .accept-line
bindkey -M menuselect "^E" .accept-line
# The following lines were added by compinstall