Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I can't get .bashrc to load on this machine... it's SUZE linux 10. I'm a bit frustrated because this seems very basic, create the file and it loads when you open a new shell connection. With the below setup I'm not seeing my changes take affect... any suggestions? I've looked over at least 8-10 threads on StackOverflow and ServerFault and haven't found a working solution.

.bash_profile

if [ -f ~/.bashrc ]; then
  . ~/.bashrc
fi

.bashrc

# Define a few Colours
BLACK='\e[0;30m'
BLUE='\e[0;34m'
GREEN='\e[0;32m'
CYAN='\e[0;36m'
RED='\e[0;31m'
PURPLE='\e[0;35m'
BROWN='\e[0;33m'
LIGHTGRAY='\e[0;37m'
DARKGRAY='\e[1;30m'
LIGHTBLUE='\e[1;34m'
LIGHTGREEN='\e[1;32m'
LIGHTCYAN='\e[1;36m'
LIGHTRED='\e[1;31m'
LIGHTPURPLE='\e[1;35m'
YELLOW='\e[1;33m'
WHITE='\e[1;37m'
NC='\e[0m'              # No Color

# check the window size after each command and, if necessary,
# update the values of LINES and COLUMNS.
shopt -s checkwinsize
share|improve this question

1 Answer 1

up vote 0 down vote accepted

does the global profile (usually in /etc/profile) tell it to load any user profiles?

this can be simply done by:

if [ -f /home/$USER/.bash_profile ]; then
  source /home/$USER/.bash_profile
fi
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.