Tuesday, May 6, 2014

Customize command prompt

Here is a way to customize the command prompt:


user_name@debian:~$ echo $PS1
\[\e]0;\u@\h: \w\a\]${debian_chroot:+($debian_chroot)}\u@\h:\w\$
user_name@debian:~$ PS1="$ "



user_name@debian:~$ nano ~/.bashrc

Add this line:

export PS1="$ "



Press Ctrl + x

Press y

Log out and log in.


The command prompt will become "$ ".



Reference

http://www.cyberciti.biz/tips/howto-linux-unix-bash-shell-setup-prompt.html

No comments:

RSS