Eclipse comes with EGit.
Get contrib/completion/git-completion.bash
. See bash/zsh completion support for core Git. Then add it to .bashrc
.
. ~/git-completion.bash
. ~/git-prompt.sh
export GIT_PS1_SHOWDIRTYSTATE=1
export PS1='\w$(__git_ps1 " (%s)")\$ '