Adding this to
~/.bashrc
:
(para editar : sudo nano ~/.bashrc )
parse_git_branch() { git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/(\1)/' }export PS1="\u@\h \[\e[32m\]\w \[\e[91m\]\$(parse_git_branch)\[\e[00m\]$ "
Restart the terminal, or source
~/.bashrc
, and it works:
No hay comentarios:
Publicar un comentario