开源的zsh配置工具,它的主题和插件系统能够为zsh扩展外观和不少有用的功能,官方是这样介绍的:git
Oh-My-Zsh is an open source, community-driven framework for managing your ZSH configuration. It comes bundled with a ton of helpful functions, helpers, plugins, themes, and a few things that make you shout...github
Ubuntu默认的终端样式,用了好久,其实也不差shell
可是用上oh-my-zsh后,更加美观且实用vim
1.安装zsh:sudo apt install zsh
bash
2.确认安装:zsh --version
curl
3.设置为默认shell:sudo chsh www -s $(which zsh)
工具
4.注销从新登录字体
默认的zsh很简陋,就不截图了url
1.安装:sh -c "$(curl -fsSL https://raw.github.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"
插件
2.设置主题为agnoster
: vim ~/.zshrc
ZSH_THEME="agnoster"
3.默认用户下隐藏user@hostname
: vim ~/.zshrc
export DEFAULT_USER="www"
此时终端是这样的,由于字体不支持,显示很奇怪
angoster
这个主题须要Powerline-patched font
这个字体才能正常
1.安装
# clone git clone https://github.com/powerline/fonts.git # install cd fonts ./install.sh # clean-up a bit cd .. rm -rf fonts
2.设置终端字体
打开Edit->Profiles->Default->Edit->Font
, 选择Ubuntu Mono derivative Powerline
至此完成了最简单的配置,感觉飞起的命令行吧!
参考: