bashのプロンプトにgitのbranchを表示する
コンソールのプロンプトの部分にgitのbranch名を表示させる設定。
~/.bashrcに追記
# show name of git branch
if [ -f $BASH_COMPLETION_DIR/git ]; then
export PS1='\[\033[01;32m\]\u@\h\[\033[01;33m\] \w$(__git_ps1) \[\033[01;34m\]\$\[\033[00m\] '
else
export PS1='\[\033[01;32m\]\u@\h\[\033[01;33m\] \w \[\033[01;34m\]\$\[\033[00m\] '
fi