# source bash.bashrc for both login and non login shells # note: bash.bashrc sources the base shell repo echo in profile.d/bash.sh if [ "${SHELL-}" ] && [ "$SHELL" != "/bin/sh" ] && [ -f /etc/bash.bashrc ]; then # uncomment for debugging echo sourcing bash.bashrc now from /etc/profile.d/bash.sh source /etc/bash.bashrc [ $EUID -ne 0 ] && startup_load # if not root source this else # set up basic stuff (e.g a prompt) if not able to source bash.bashrc echo Unable to source bash.bashrc, Setting up red prompt for root and a green one for users. NORMAL="\[\e[0m\]" RED="\[\e[1;31m\]" GREEN="\[\e[1;32m\]" if [[ $EUID == 0 ]] ; then PS1="$RED\u [ $NORMAL\w$RED ]# $NORMAL" else PS1="$GREEN\u [ $NORMAL\w$GREEN ]\$ $NORMAL" fi unset RED GREEN NORMAL fi