Example Prompts from the Prompt-o-matic

PS1="\[\033[0;33m\]-\[\033[1;33m\]-\[\033[1;34m\](\[\033[1;33m\]\h\[\033[1;34m\]:\[\033[1;33m\]\$(temp=\$(cat /proc/uptime) && upSec=\${temp%%.*} ; let secs=\$((\${upSec}%60)) ; let mins=\$((\${upSec}/60%60)) ; let hours=\$((\${upSec}/3600%24)) ; let days=\$((\${upSec}/86400)) ; if [ "\${days}" -ne "0" ]; then echo -n "\${days}d"; fi ; echo -n "\${hours}h\${mins}m")\[\033[0;34m\]|\[\033[0;33m\]\!\[\033[0;34m\]|\[\033[0;36m\]\$(ls --si -s | head -1 | awk '{print \$2}')\[\033[0;34m\]|\[\033[1;37m\]\${PWD}\[\033[1;34m\])\[\033[1;33m\]-\[\033[0;33m\]-\n\[\033[0;33m\]-\[\033[1;33m\]-\[\033[1;34m\](\[\033[1;33m\]\u\[\033[0;34m\]:\[\033[1;37m\]$ \[\033[0m\]"


PS1="\[\033[1;35m\][\[\033[1;33m\]\!\[\033[1;35m\]|\[\033[1;33m\]\${PWD}\[\033[1;35m\]]\n\[\033[1;35m\][\[\033[1;33m\]\u\[\033[1;35m\]@\[\033[1;33m\]\h\[\033[1;35m\]]\[\033[1;37m\]$ \[\033[0m\]"


PS1="\[\033[0m\]\[\033[1;35m\]\$(ps ax | wc -l | tr -d ' ') \[\033[0m\]\[\033[0;35m\]\$(temp=\$(cat /proc/loadavg) && echo \${temp%% *}) \[\033[0m\]\[\033[1;34m\]\$(temp=\$(cat /proc/uptime) && upSec=\${temp%%.*} ; let secs=\$((\${upSec}%60)) ; let mins=\$((\${upSec}/60%60)) ; let hours=\$((\${upSec}/3600%24)) ; let days=\$((\${upSec}/86400)) ; if [ "\${days}" -ne "0" ]; then echo -n "\${days}d"; fi ; echo -n "\${hours}h\${mins}m") \[\033[0m\]\[\033[0;33m\]\$(ls -l | grep \"^-\" | wc -l | tr -d \" \")\[\033[0m\]\[\033[0;37m\]->\[\033[0m\]\[\033[1;33m\]\$(ls --si -s | head -1 | awk '{print \$2}') \[\033[0m\]\[\033[1;35m\]\${PWD}\n\[\033[0m\]\[\033[1;35m\]\t \[\033[0m\]\[\033[0;35m\]\! \[\033[0m\]\[\033[1;33m\]\u\[\033[0m\]\[\033[0;37m\]@\[\033[0m\]\[\033[0;33m\]\h \[\033[0m\]\[\033[1;37m\]$ \[\033[0m\]"


PS1="\[\033[0m\]\[\033[1;31m\](\[\033[0m\]\[\033[0;35m\]\u\[\033[0m\]\[\033[1;31m\]@\[\033[0m\]\[\033[0;35m\]\h\[\033[0m\]\[\033[1;31m\])\[\033[0m\]\[\033[1;37m\]--\[\033[0m\]\[\033[1;31m\](\[\033[0m\]\[\033[0;35m\]\${PWD}\[\033[0m\]\[\033[1;31m\]:\[\033[0m\]\[\033[0;35m\]\$(ls -l | grep \"^-\" | wc -l | tr -d \" \")\[\033[0m\]\[\033[1;31m\]/\[\033[0m\]\[\033[0;35m\]\$(ls --si -s | head -1 | awk '{print \$2}')\[\033[0m\]\[\033[1;31m\])\[\033[0m\]\[\033[1;37m\]-\n(\[\033[0m\]\[\033[0;35m\]\!\[\033[0m\]\[\033[1;37m\])\[\033[0m\]\[\033[1;31m\]\$ \[\033[0m\]"

A slight cheat was needed to get this to work, as it includes an exclamation point. This one includes a titlebar, which is now added by default.

case $TERM in xterm*|rxvt*) TITLEBAR='\[\033]0;\u@\h:\w\007\]' ;; *) TITLEBAR="" ;; esac; PS1="${TITLEBAR}\[\033[0m\]\[\033[1;32m\]\$(ps ax | wc -l | tr -d ' ')proc\[\033[0m\]\[\033[0;32m\] - \[\033[0m\]\[\033[1;33m\]\041\!\[\033[0m\]\[\033[0;32m\] - \[\033[0m\]\[\033[1;32m\]\$(ls -l | grep \"^-\" | wc -l | tr -d \" \")(\$(ls --si -s | head -1 | awk '{print \$2}'))\[\033[0m\]\[\033[0;32m\] - \[\033[0m\]\[\033[1;33m\]\${PWD}\n\[\033[0m\]\[\033[1;33m\]\u\[\033[0m\]\[\033[0;32m\]@\[\033[0m\]\[\033[1;32m\]\h\[\033[0m\]\[\033[0;32m\](\[\033[0m\]\[\033[1;32m\]\l\[\033[0m\]\[\033[0;32m\])\[\033[0m\]\[\033[1;37m\]\$ \[\033[0m\]"


http://www.gilesorr.com/bashprompt/jsb/examples.html (3.6Kb)
Last modified 20060518 by giles