linux配置powerline(bash/vim)美化

安装powerline需要pip

链接:https://pan.baidu.com/s/1Jc59VD35PYic2fTK5v8h1w 密码:otfp

pip

curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
python get-pip.py

利用pip安装powerline

powerline

pip install powerline-status

测试

pip show powerline-status

安装字体

下载

wget https://github.com/powerline/powerline/raw/develop/font/PowerlineSymbols.otf
wget https://github.com/powerline/powerline/raw/develop/font/10-powerline-symbols.conf

安装

cp PowerlineSymbols.otf /usr/share/fonts
执行命令刷新加入字体
fc-cache -vf /usr/share/fonts/
(如果没有fc-cache则需安装fontconfig) cp 10-powerline-symbols.conf /etc/fonts/conf.d/

配置bash

vim ~/.bashrc

#powerline
if [ -f `which powerline-daemon` ];then
powerline-daemon -q
POWERLINE_BASH_CONTINUATION=1
POWERLINE_BASH_SELECT=1
. /usr/local/lib/python2.7/dist-packages/powerline/bindings/bash/powerline.sh
fi
export TERM="screen-256color"

source ~/.bashrc

效果

linux配置powerline(bash/vim)美化

配置vim

vim ~/.vimrc

set rtp+=/usr/local/lib/python2.7/dist-packages/powerline/bindings/vim
set laststatus=2
set t_Co=256

source ~/.vimrc

效果

linux配置powerline(bash/vim)美化

linux配置powerline(bash/vim)美化

骚起来吧。

上一篇:实现多表关联来方便你的SELECT查询功能


下一篇:[Android Pro] Gradle Tips#1-tasks