环境
Deepin 15.11
安装
- 安装zsh
sudo apt install zsh
- 安装oh-my-zsh
wget https://raw.github.com/robbyrussell/oh-my-zsh/master/tools/install.sh -O - | sh
配置
- 设置zsh为默认shell
chsh -s /bin/zsh
- 对oh-my-zsh目录授权
chmod -R 777 ~/.oh-my-zsh
- 设置跳过不安全目录验证
~/.zshrc
# on the top of the files
ZSH_DISABLE_COMPFIX="true"
插件安装
~/.zshrc
# Which plugins would you like to load?
# Standard plugins can be found in ~/.oh-my-zsh/plugins/*
# Custom plugins may be added to ~/.oh-my-zsh/custom/plugins/
# Example format: plugins=(rails git textmate ruby lighthouse)
# Add wisely, as too many plugins slow down shell startup.
plugins=(
git
zsh-autosuggestions
colored-man-pages
)
# 文件末尾
source "$ZSH_CUSTOM/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh"
- 提示
git clone https://github.com/zsh-users/zsh-autosuggestions $ZSH_CUSTOM/plugins/zsh-autosuggestions
- 高亮
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git $ZSH_CUSTOM/plugins/zsh-syntax-highlighting
source ~/.zshrc