# 下载 https://www.iterm2.com/downloads.html,并安装
chsh -s /bin/zsh
# 安装 oh-my-zsh
sh -c "$(curl -fsSL https://raw.github.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"
# 下载主题
git clone https://github.com/bhilburn/powerlevel9k.git ~/.oh-my-zsh/custom/themes/powerlevel9k
# 编辑配置文件
vim ~/.zshrc
POWERLEVEL9K_CONTEXT_TEMPLATE="❤️"
POWERLEVEL9K_RIGHT_PROMPT_ELEMENTS=()
ZSH_THEME="powerlevel9k/powerlevel9k"
# 安装字体
sudo easy_install pip
pip install powerline-status --user
# 这里报错了。默认Python版本是2.7.16
解决办法:
wget https://bootstrap.pypa.io/pip/3.5/get-pip.py
python3 get-pip.py.1
参考链接:
https://blog.csdn.net/lzRush/article/details/114213053
pip3 install powerline-status --user # 这里我改用pip3
git clone https://github.com/powerline/fonts.git --depth=1
cd fonts ./install.sh
# 或者
Monaco for Powerline
git clone https://github.com/supermarin/powerline-fonts
# 高亮插件
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting
# 在 ~/.zshrc 最后一行加入
source ~/.oh-my-zsh/custom/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh
# 补全插件
cd ~/.oh-my-zsh/custom/plugins
git clone https://github.com/zsh-users/zsh-autosuggestions
# 在~/.zshrc 配置
plugins=(zsh-autosuggestions zsh-syntax-highlighting)
# 安装配色
git clone https://github.com/altercation/solarized
cd solarized/iterm2-colors-solarized/ open .
# 或者
git clone https://github.com/mbadolato/iTerm2-Color-Schemes
Solarized Dark.itermcolors和Solarized Light.itermcolors schemes/Solarized Dark Higher Contrast.itermcolors
# 快捷键
# option+q: b send escape sequence
# option+e: f send escape sequence