參考博客:linux
http://blog.csdn.net/zly9923218/article/details/51967923git
vim ~/.bash_profile
插入代碼:github
#enables colorin the terminal bash shell export export CLICOLOR=1 #sets up thecolor scheme for list export export LSCOLORS=gxfxcxdxbxegedabagacad #sets up theprompt color (currently a green similar to linux terminal) export PS1='\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;36m\]\w\[\033[00m\]\$ ' #enables colorfor iTerm export TERM=xterm-color
執行:shell
source ~/.bash_profile
官網提供的配色方案:iTerm2-Color-Schemes,根據圖片顯示風格下載喜歡的配色,vim
我用的是solarized,即iterm2-colors-solarized下的
Solarized Dark
Solarized Dark.itermcolors
bash
設置:spa
preference->profiles->Terminal->xterm-new.net
->colors->LoadPresents,import配色方案文件code
重啓iterm文件。blog