Closed mhesselbarth closed 5 years ago
Update...I'm now using .profile to enable using .bashrc on Scientific Linux Link.
case "$SHELL" in
/bin/bash)
. /etc/bashrc
. .bashrc
;;
/usr/bin/bash)
. /etc/bashrc
. .bashrc
;;
/usr/local/bin/bash)
. /etc/bashrc
. .bashrc
;;
*) ;;
esac
This allows me in my .bashrc to source .bash_modules to load all modules and .bash_aliases (#3) to load some aliases.
# .bashrc
# Source global definitions
if [ -f /etc/bashrc ]; then
. /etc/bashrc
fi
# load aliases
if [ -f ~/.bash_aliases ]; then
. ~/.bash_aliases
fi
# load modules
if [ -f ~/.bash_modules ]; then
. ~/.bash_modules
fi
Finally, I load all modules in .bash_modules.
module load gcc
module load zeromq
module load R_GEO
One the first glance, this might seem a bit complicated, however, I think this keeps everything quite organized.
Updated on homepage
It seems like .profile is not needed any more for SLURM and .bashrc can be streamlined