From cc7ff386ae1d3e6c8cabebc88439c21f93b2da47 Mon Sep 17 00:00:00 2001 From: root Date: Fri, 7 Dec 2018 10:17:38 +0100 Subject: [PATCH] modified my .bashrc (different colors for users and root) --- .bashrc | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/.bashrc b/.bashrc index 4745ec9..8cd095d 100644 --- a/.bashrc +++ b/.bashrc @@ -68,13 +68,15 @@ fi # set a fancy prompt if [ $UID == 0 ]; then # root: red - PS_COLOR="\[\033[1;31m\]" + #PS_COLOR="\[\033[1;31m\]" + export PS1="\t \[$(tput bold)\]\[$(tput sgr0)\]\[\033[38;5;1m\]\u\[$(tput sgr0)\]\[$(tput sgr0)\]\[\033[38;5;7m\]@\h\[$(tput sgr0)\]\[\033[38;5;15m\]:\[$(tput sgr0)\]\[\033[38;5;1m\]\w\[$(tput sgr0)\]\[\033[38;5;15m\]\n\\$ \[$(tput sgr0)\]" else # user - PS_COLOR="\[\033[33m\]" + #PS_COLOR="\[\033[33m\]" + export PS1="\t \[$(tput sgr0)\]\[\033[38;5;3m\]\u\[$(tput sgr0)\]\[\033[38;5;7m\]@\h\[$(tput sgr0)\]\[\033[38;5;15m\]:\[$(tput sgr0)\]\[\033[38;5;87m\]\w\[$(tput sgr0)\]\[\033[38;5;15m\]\n\\$ \[$(tput sgr0)\]" fi -#PS1="\t ${PS_COLOR}${debian_chroot:+($debian_chroot)}\u\[\033[0m\]@\h:\w\$ " -export PS1="\t \[$(tput sgr0)\]\[\033[38;5;11m\]\u\[$(tput sgr0)\]\[\033[38;5;15m\]@\h:\[$(tput sgr0)\]\[\033[38;5;87m\]\w\[$(tput sgr0)\]\[\033[38;5;15m\] \n\\$ \[$(tput sgr0)\]" +#PS1="\t ${PS_COLOR}${debian_chroot:+($debian_chroot)}\u@\h:\w\$ " +#export PS1="\t \[$(tput sgr0)\]\[\033[38;5;11m\]\u\[$(tput sgr0)\]${PS_COLOR}@\h:\[$(tput sgr0)\]\[\033[38;5;87m\]\w\[$(tput sgr0)\]\[\033[38;5;15m\] \n\\$ \[$(tput sgr0)\]" # if this is an xterm modify the title case $TERM in