Velocities and forces for selections.
[gromacs/qmmm-gamess-us.git] / scripts / GMXRC.bash.in
bloba68a771c5b51fdb324328a2a5c80ab25cb5761a1
1 # zsh configuration file for Gromacs
2 # First we remove old gromacs stuff from the paths
3 # by selecting everything else.
4 # This is not 100% necessary, but very useful when we
5 # repeatedly switch between gmx versions in a shell.
7 # First remove gromacs part of ld_library_path
8 tmppath=""
9 for i in `echo $LD_LIBRARY_PATH | sed "s/:/ /g"`; do
10 if test "$i" != "$GMXLDLIB"; then
11 tmppath=${tmppath}:$i
13 done
14 LD_LIBRARY_PATH=$tmppath
16 # remove gromacs part of path
17 tmppath=""
18 for i in `echo $PATH | sed "s/:/ /g"`; do
19 if test "$i" != "$GMXBIN"; then
20 tmppath=${tmppath}:$i
22 done
23 PATH=$tmppath
25 # and remove the gmx part of manpath
26 tmppath=""
27 for i in `echo $MANPATH | sed "s/:/ /g"`; do
28 if test "$i" != "$GMXMAN"; then
29 tmppath=${tmppath}:$i
31 done
32 MANPATH=$tmppath
34 ##########################################################
35 # This is the real configuration part. We save the Gromacs
36 # things in separate vars, so we can remove them later.
37 # If you move gromacs, change the next four line.
38 ##########################################################
39 GMXBIN=@bindir@
40 GMXLDLIB=@libdir@
41 GMXMAN=@mandir@
42 GMXDATA=@datadir@
44 # NB: The variables already begin with ':' now, or are empty
45 LD_LIBRARY_PATH=${GMXLDLIB}${LD_LIBRARY_PATH}
46 PATH=${GMXBIN}${PATH}
47 MANPATH=${GMXMAN}${MANPATH}
49 # export should be separate, so /bin/sh understands it
50 export GMXBIN GMXLDLIB GMXMAN GMXDATA LD_LIBRARY_PATH PATH MANPATH
52 # read bash completions if understand how to use them
53 # and this shell supports extended globbing
54 if (complete) > /dev/null 2>&1; then
55 if (shopt -s extglob) > /dev/null 2>&1; then
56 if [ -f $GMXBIN/completion.bash ]; then
57 source $GMXBIN/completion.bash;