Skip to content

Instantly share code, notes, and snippets.

@alanmaciel
Created November 3, 2012 16:43
Show Gist options
  • Save alanmaciel/4007866 to your computer and use it in GitHub Desktop.
Save alanmaciel/4007866 to your computer and use it in GitHub Desktop.
MY LOVELY PROMPT
if [[ $COLORTERM = gnome-* && $TERM = xterm ]] && infocmp gnome-256color >/dev/null 2>&1; then
export TERM=gnome-256color
elif infocmp xterm-256color >/dev/null 2>&1; then
export TERM=xterm-256color
fi
export GIT_PS1_SHOWDIRTYSTATE=true
export GIT_PS1_SHOWUNTRACKEDFILES=true
export GIT_PS1_SHOWSTASHSTATE=true
[[ -s "$HOME/.rvm/contrib/ps1_functions" ]] && source "$HOME/.rvm/contrib/ps1_functions"
# My prompt Alan Maciel 2012
# ┌[21:43:15][alan@ono-sendai][git:master:79341e1][ruby-1.8.7-p370@shoppertown-development]
# └[~/repo/shoppertownsite]∴
# letrero = $(ps1_titlebar "[%s]")
#
# hora \[\033[0;37m\][\t\[\033[0;37m\]]
# user y host \[\033[0;33m\][\[\033[0;36m\]\u\[\033[0;36m\]@\[\033[0;36m\]\h
# pwd \[\033[0;33m\][\[\033[0;32m\]\w\[\033[0;33m\]]
# $ prompt \[\033[0;37m\]\\$ \[\033[00m\]
# git \[\033[0;31m\]$(__git_ps1 "[%s]")
# PS1='\[\033[0;37m\]┌[\[\033[0;36m\]\t\[\033[0;37m\]\[\033[0;37m\]]\[\033[0;34m\]\[\033[0;37m\][\[\033[0;34m\]$(ps1_rvm)\[\033[0;37m\]]$(__git_ps1 "\[\033[0;37m\][\[\033[0;35m\]git:%s\[\033[0;37m\]]")\n\[\033[0;37m\]└\[\033[0;37m\][\[\033[0;32m\]\u\[\033[0;32m\]@\[\033[0;32m\]\h\[\033[0;37m\]\[\033[0;37m\]:\[\033[0;33m\]\w\[\033[0;37m\]]\[\033[0;32m\] ∴ \[\033[0;37m\]'
#┌[00:04:53][ruby-1.9.3-p194]
#└[alan@ono-sendai:~] ∴
#PS1='\[\033[0;37m\]\[\033[0;37m\]\[\033[0;32m\]\u\[\033[0;32m\]@\[\033[0;32m\]\h\[\033[0;37m\]\[\033[0;37m\]:\[\033[0;33m\]\w\[\033[0;37m\]\[\033[0;32m\] \[\033[0;34m\]\[\033[0;37m\][\[\033[0;36m\]$(ps1_rvm)\[\033[0;37m\]]\n$(__git_ps1 "\[\033[0;37m\][\[\033[0;36m\]git:%s\[\033[0;37m\]]")→ \[\033[0;37m\]'
#alan@ono-sendai:~/repo/Fut11 [ruby-1.8.7-p370@fut11]
#[git:dev *]→
if [[ ${EUID} == 0 ]] ; then
PS1='\[\033[0;37m\][\t\[\033[0;37m\]]\[\033[0;33m\][\[\033[0;36m\]\u\[\033[0;36m\]@\[\033[0;36m\]\h \[\033[1;31m\]\w\[\033[0;33m\]]\[\033[0;31m\]$(__git_ps1 "(%s)")\[\033[0;37m\]\\$ \[\033[00m\]\n[$(ps1_titlebar)] ∴ '
else
#PS1='\[\033[0;37m\]\[\033[0;37m\]\[\033[0;32m\]\u\[\033[0;32m\]@\[\033[0;32m\]\h\[\033[0;37m\]\[\033[0;37m\]:\[\033[0;33m\]\w\[\033[0;37m\]\[\033[0;32m\] \[\033[0;34m\]\[\033[0;37m\][\[\033[0;36m\]$(ps1_rvm)\[\033[0;37m\]]\n$(__git_ps1 "\[\033[0;37m\][\[\033[0;36m\]git:%s\[\033[0;37m\]]")→ \[\033[0;37m\]'
#PS1='\[\033[0;37m\]┌[\[\033[0;34m\]\t\[\033[0;37m\]\[\033[0;37m\]]\[\033[0;36m\]\[\033[0;37m\][\[\033[0;36m\]$(ps1_rvm)\[\033[0;37m\]]$(__git_ps1 "\[\033[0;37m\][\[\033[0;36m\]git:%s\[\033[0;37m\]]")\n\[\033[0;37m\]└\[\033[0;37m\][\[\033[0;34m\]\u\[\033[0;34m\]@\[\033[0;34m\]\h\[\033[0;37m\]\[\033[0;37m\]:\[\033[0;32m\]\w\[\033[0;37m\]]\[\033[0;32m\] ∴ \[\033[0;37m\]'
#PS1='\[\033[0;37m\]┌[\[\033[0;34m\]\t\[\033[0;37m\]\[\033[0;37m\]]\[\033[0;36m\]\[\033[0;36m\]\[\033[0;37m\][\[\033[0;34m\]\u\[\033[0;34m\]@\[\033[0;34m\]\h\[\033[0;37m\]\[\033[0;37m\]:\[\033[0;32m\]\w\[\033[0;37m\]]\[\033[0;32m\]\n\[\033[0;37m\]└[\[\033[0;36m\]$(ps1_rvm)\[\033[0;37m\]]$(__git_ps1 "\[\033[0;37m\][\[\033[0;36m\]git:%s\[\033[0;37m\]]") \n∴ \[\033[0;37m\]'
PS1='\[\033[0;37m\]\[\033[0;37m\][\[\033[0;34m\]\u\[\033[0;34m\]@\[\033[0;34m\]\h\[\033[0;37m\]\[\033[0;37m\]:\[\033[0;32m\]\w\[\033[0;37m\]]\[\033[0;32m\]\[\033[0;37m\]\[\033[0;37m\][\[\033[0;36m\]$(ps1_rvm)\[\033[0;37m\]]\n\[\033[0;37m\][\[\033[0;34m\]\t\[\033[0;37m\]]\[\033[0;36m\]\[\033[0;36m\]$(__git_ps1 "\[\033[0;37m\][\[\033[0;36m\]git:%s\[\033[0;37m\]]") ∴ \[\033[0;37m\]'
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment