安装auto-fu.zsh让命令输入自动补全

  • 下载auto-fu.zsh
1
2
cd ~/.oh-my-zsh/custom/plugins
git clone https://github.com/hchbaw/auto-fu.zsh.git auto-fu
  • 执行zcompile
1
A=~/.oh-my-zsh/custom/plugins/auto-fu/auto-fu.zsh; (zsh -c "source $A ; auto-fu-zcompile $A ~/.zsh")
  • 添加下面的设置到zshrc中
1
2
3
4
5
6
7
## auto-fu.zsh stuff.
# source ~/.oh-my-zsh/custom/plugins/auto-fu/auto-fu.zsh
{ . ~/.zsh/auto-fu; auto-fu-install; }
zstyle ':auto-fu:highlight' input bold
zstyle ':auto-fu:highlight' completion fg=black,bold
zstyle ':auto-fu:var' postdisplay $'\n-azfu-'
zle-line-init () {auto-fu-init;}; zle -N zle-line-init
  • 重新编译zshrc
1
source ~/.zshrc

你可能感兴趣的:(安装auto-fu.zsh让命令输入自动补全)