Env setup for MAC OS X

1) Install package management tool "Homebrew" for MAC
http://brew.sh/

2) Configure the Terminal's background/foreground and text colors. 

  • Default Foreground: 255/255/255
  • Default Background: 51/51/51
  • ANSI Black: 77/77/77
  • ANSI Green: 152/251/152
  • ANSI Yellow: 240/230/140
  • ANSI Blue: 205/133/63
  • ANSI Blue Bold 135/206/235
  • ANSI Magenta: 255/222/173 or 205/92/92
  • ANSI Cyan: 255/160/160
  • ANSI Cyan Bold: 255/215/0
  • ANSI White: 245/222/179
3) Customise and Highlight the console prompt of the terminal. Add the following line to ~/.bashrc

export PS1="\[\e[0;31m\]\u@\h\[\e[0;33m\]:\[\e[1;34m\]\w\[\e[1;37m\]$\[\e[m\]"

4) Configure the Terminal to execute .bashrc when startup.

Terminal -> Preferences -> Select the current profile -> Shell -> Run command (check the box of "Run inside shell")

5) Enhance the color of "ls" command
a) brew install xz coreutils
b) gdircolors --print-database >> ~/.dir_colors
c) add the following code to ~/.bashrc

if brew list |grep coreutils > /dev/null ;then
 

PATH="$(brew --prefix coreutils)/libexec/gnubin:$PATH"    

aliasls='ls -F --show-control-chars --color=auto' 

eval`gdircolors -b $HOME/.dir_colors`

fi


References:
http://www.darkrune.org/blog/?p=213 

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值