PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w' if [ "$TERM" = xterm ] ; then PS1="\[\e]0;$PS1\a$(tput bold)\]\$? \! $PS1\\$\[$(tput sgr0)\] " else PS1="\[$(tput bold)\]\$? \! $PS1\\$\[$(tput sgr0)\] " fiThe prompt prints the exit code of the last command, the history id if the current command, the user name, the host name and the working directory.
It is also possible to send the prompt to other systems accessed with SSH. For this it is necessary to export the PS1 environment variable:
export PS1The SSH daemon of the target system must accept the variable. Put the following line in /etc/ssh/sshd_config:
AcceptEnv PS1And add the following line to your local SSH configuration in .ssh/config:
SendEnv PS1After that you have on your local and target system the same prompt without the need to synchronize any bashrc files.