Subversion Repositories configs

Rev

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
203 - 1
scl()
2
{
3
if [ "$1" = "load" -o "$1" = "unload" ]; then
4
# It is possible that function module is not declared in time of this
5
# declaration so eval is used instead of direct calling of function module
6
    eval "module $@"
7
else
8
   /usr/bin/scl "$@"
9
fi
10
}
11
 
12
shell=`/bin/basename \`/bin/ps -p $$ -ocomm=\``
13
[ "$shell" = "bash" ] && export -f scl # export -f works only in bash
14
 
15
MODULESHOME=/usr/share/Modules
16
export MODULESHOME
17
 
18
if [ "${MODULEPATH:-}" = "" ]; then
19
   MODULEPATH=`sed -n 's/[   #].*$//; /./H; $ { x; s/^\n//; s/\n/:/g; p; }' ${MODULESHOME}/init/.modulespath`
20
fi
21
 
22
MODULEPATH=/etc/scl/modulefiles:$MODULEPATH
23
 
24
export MODULEPATH
25
 
26