Smiley Face Bash Prompt

$ PS1="\`if [ \$? = 0 ]; then echo \[\e[34m\]^_^\[\e[0m\]; else echo
\[\e[31m\]O_O\[\e[0m\]; fi\`...@\h:\w]\\$ "

If your last command was a dud, your bash prompt will be angry at you.
Otherwise it's happy. Soon you will crave its constant approval and
your linux skills will improve simply to avoid low self-esteem.

To set this as default, edit your ".bashrc" file and add it.

Ex:

^_^[stud...@mercury:~]$ echo "Linux Rockzzz"
Linux Rockzzz
^_^[stud...@mercury:~]$ ;echo "You want windows"
bash: syntax error near unexpected token `;'
o_o[stud...@mercury:~]$ echo "hehe"
hehe
^_^[stud...@mercury:~]$





--
Regards,
Tha.Suresh

Cooool Linux Tips & Tricks,
http://gnutips.wordpress.com

My experiences with Linux are here,
http://thasulinux.wordpress.com
_______________________________________________
ILUGC Mailing List:
http://www.ae.iitm.ac.in/mailman/listinfo/ilugc

Reply via email to