From 98a2e4c24b6ee8823b918d8b7a3cb30783256132 Mon Sep 17 00:00:00 2001 From: juan Date: Sun, 12 Jun 2022 22:43:55 +0800 Subject: [PATCH] Update zshrc --- .zshrc | 42 +++++++++++++++++++++++++++++------------- 1 file changed, 29 insertions(+), 13 deletions(-) diff --git a/.zshrc b/.zshrc index fd48de2..6fcc53b 100644 --- a/.zshrc +++ b/.zshrc @@ -34,33 +34,44 @@ zinit light zsh-users/zsh-history-substring-search autoload -Uz _zinit (( ${+_comps} )) && _comps[zinit]=_zinit -zstyle ':completion:*' auto-description 'specify: %F{magenta}%d%f' -zstyle ':completion:*' completer _expand _complete _ignored _correct _approximate +eval `dircolors` +# The following lines were added by compinstall + +zstyle ':completion:*' auto-description 'Specify: %F{magenta}%d%f' +zstyle ':completion:*' completer _oldlist _expand _complete _ignored _match _correct _approximate _prefix +zstyle ':completion:*' completions 1 zstyle ':completion:*' expand prefix suffix -zstyle ':completion:*' file-sort name +zstyle ':completion:*' file-sort access zstyle ':completion:*' format 'Completing %F{magenta}%d%f' +zstyle ':completion:*' glob 1 zstyle ':completion:*' group-name '' +zstyle ':completion:*' ignore-parents parent pwd .. zstyle ':completion:*' insert-unambiguous true -zstyle ':completion:*' list-colors '' -zstyle ':completion:*' list-suffixes true -zstyle ':completion:*' matcher-list '' 'm:{[:lower:]}={[:upper:]} m:{[:lower:][:upper:]}={[:upper:][:lower:]}' 'r:|[._-]=** r:|=**' 'l:|=* r:|=*' +zstyle ':completion:*' list-colors ${(s.:.)LS_COLORS} +zstyle ':completion:*' list-prompt %SAt %p: Hit TAB for more, or the character to insert%s +zstyle ':completion:*' matcher-list '' 'm:{[:lower:][:upper:]}={[:upper:][:lower:]}' 'r:|[._-]=** r:|=**' +zstyle ':completion:*' max-errors 8 numeric zstyle ':completion:*' menu select=1 -zstyle ':completion:*' original true +zstyle ':completion:*' original false zstyle ':completion:*' preserve-prefix '//[^/]##/' -zstyle ':completion:*' select-prompt %SScrolling active: current selection at %F{blue}%p%s%f %l -zstyle ':completion:*' verbose true +zstyle ':completion:*' prompt 'Completing, with %e errors' +zstyle ':completion:*' select-prompt %SScrolling active: current selection at %p%s +zstyle ':completion:*' substitute 1 +zstyle ':completion:*' use-compctl true zstyle :compinstall filename '/home/juan/.zshrc' + autoload -Uz compinit compinit -HISTFILE=~/.cache/.zhistory +# End of lines added by compinstall +# Lines configured by zsh-newuser-install +HISTFILE=~/.cache/zhistory HISTSIZE=8192 SAVEHIST=8192 setopt autocd extendedglob nomatch notify auto_pushd unsetopt beep -zmodload zsh/complist - -#vi mone bindkey -v +# End of lines configured by zsh-newuser-install + export KEYTIMEOUT=1 #edit in vim @@ -68,6 +79,7 @@ autoload edit-command-line zle -N edit-command-line bindkey '' edit-command-line +zmodload zsh/complist bindkey -M menuselect 'h' vi-backward-char bindkey -M menuselect 'k' vi-up-line-or-history bindkey -M menuselect 'l' vi-forward-char @@ -75,9 +87,13 @@ bindkey -M menuselect 'j' vi-down-line-or-history bindkey '^[[A' history-substring-search-up bindkey '^[[B' history-substring-search-down +bindkey '' history-substring-search-up +bindkey '' history-substring-search-down bindkey ' ' magic-space +bindkey '' autosuggest-execute + #config location export GOPATH=$HOME/.cache/go export LESSHISTFILE=/dev/null