3 # Useful shell to run executable progs or shells under Salome env
4 # Use it with args to run a program : runSession python -i myprog.py
5 # Use it without args to run an interactive shell under Salome env
8 # --- retrieve APPLI path, relative to $HOME
9 # on sarge, "which" gives not allways the absolute path...
13 if test x$aa == x\/; then
15 elif test x$aa == x\.; then
16 mycom=${PWD}/${comName:2}
18 mycom=${PWD}/${comName}
20 APPLI=`echo ${HOME} \`dirname $mycom\` | awk ' { print substr($2,length($1)+2) } '`
24 # --- set the SALOME environment (prerequisites, MODULES_ROOT_DIR...)
26 . ${HOME}/${APPLI}/envd ${HOME}/${APPLI}
29 export OMNIORB_CONFIG=${HOME}/${APPLI}/.omniORB_${myhost}_last.cfg
31 # --- invoque shell with or without args
33 if [ $# -ne 0 ] ; then
34 ${KERNEL_ROOT_DIR}/bin/salome/envSalome.py /bin/bash --rcfile ${HOME}/${APPLI}/.bashrc -c "$*"
37 ${KERNEL_ROOT_DIR}/bin/salome/envSalome.py /bin/bash --rcfile ${HOME}/${APPLI}/.bashrc