Arch之道

zsh安装配置

2018-11-18  本文已影响65人  _narcissus

zsh配置好了是很好看的

我的 zsh配置文件

export TERM="xterm-256color" 
#common setting
autoload -Uz compinit promptinit
compinit
promptinit
zstyle ':completion::complete:*' gain-privileges 1
zstyle ':completion:*' menu select

#theme setting
POWERLEVEL9K_MODE='awesome-fontconfig'
source /usr/share/zsh-theme-powerlevel9k/powerlevel9k.zsh-theme
POWERLEVEL9K_LEFT_PROMPT_ELEMENTS=(load dir vcs ssh dir_writable)
POWERLEVEL9K_RIGHT_PROMPT_ELEMENTS=(status root_indicator background_jobs history newline)
#use to highlight syntax like fish
source /usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh

#highlight man 
man() {
    LESS_TERMCAP_md=$'\e[01;31m' \
    LESS_TERMCAP_me=$'\e[0m' \
    LESS_TERMCAP_se=$'\e[0m' \
    LESS_TERMCAP_so=$'\e[01;44;33m' \
    LESS_TERMCAP_ue=$'\e[0m' \
    LESS_TERMCAP_us=$'\e[01;32m' \
    command man "$@"
  }

#user alias
alias l='ls -lh --color=auto'

上一篇下一篇

猜你喜欢

热点阅读