Changeset c5074d2 in flex_extract.git for templates/compilejob.template


Ignore:
Timestamp:
Oct 9, 2018, 8:42:16 PM (16 months ago)
Author:
Anne Philipp <anne.philipp@…>
Branches:
dev
Children:
aa275fc
Parents:
0a06607
Message:

added making of namelist file and jobscript via genshi templates

File:
1 edited

Legend:

Unmodified
Added
Removed
  • templates/compilejob.template

    r0aaeb04 rc5074d2  
    1717##PBS -q ns
    1818##PBS -S /usr/bin/ksh
    19 ##PBS -o /scratch/ms/$usergroup/$username/flex_ecmwf.$Jobname.$Job_ID.out
     19##PBS -o /scratch/ms/$usergroup/$username/flex_ecmwf.$${Jobname}.$${Job_ID}.out
    2020# job output is in .ecaccess_DO_NOT_REMOVE
    2121##PBS -j oe
     
    2626set -x
    2727export VERSION=$version_number
    28 case $HOST in
     28case $${HOST} in
    2929  *ecg*)
    3030  module load python
     
    4141  module load emos
    4242  module load python
    43   echo ${GROUP}
    44   echo ${HOME}
    45   echo $HOME | awk -F / '{print $1, $2, $3, $4}'
    46   export GROUP=`echo $HOME | awk -F / '{print $4}'`
    47   export SCRATCH=/scratch/ms/${GROUP}/${USER}
     43  echo $${GROUP}
     44  echo $${HOME}
     45  echo $${HOME} | awk -F / '{print $1, $2, $3, $4}'
     46  export GROUP=`echo $${HOME} | awk -F / '{print $4}'`
     47  export SCRATCH=/scratch/ms/$${GROUP}/$${USER}
    4848  export FLEXPART_ROOT_SCRIPTS=$fp_root_scripts
    4949  export MAKEFILE=$makefile
     
    5151esac
    5252
    53 mkdir -p $FLEXPART_ROOT_SCRIPTS/flex_extract_v$VERSION
    54 cd $FLEXPART_ROOT_SCRIPTS/flex_extract_v$VERSION   # if FLEXPART_ROOT is not set this means cd to the home directory
    55 tar -xvf $HOME/flex_extract_v$VERSION.tar
     53mkdir -p $${FLEXPART_ROOT_SCRIPTS}/flex_extract_v$${VERSION}
     54cd $${FLEXPART_ROOT_SCRIPTS}/flex_extract_v$${VERSION}   # if FLEXPART_ROOT is not set this means cd to the home directory
     55tar -xvf $${HOME}/flex_extract_v$${VERSION}.tar
    5656cd src
    5757\rm *.o *.mod $fortran_program
    58 make -f $MAKEFILE >flexcompile 2>flexcompile
     58make -f $${MAKEFILE} >flexcompile 2>flexcompile
    5959
    6060ls -l $fortran_program >>flexcompile
    61 if [ $? -eq 0 ]; then
     61if [ $$? -eq 0 ]; then
    6262  echo 'SUCCESS!' >>flexcompile
    63   mail -s flexcompile.$HOST.$$ $USER <flexcompile
     63  mail -s flexcompile.$${HOST}.$$$$ $${USER} <flexcompile
    6464else
    6565  echo Environment: >>flexcompile
    6666  env >> flexcompile
    67   mail -s "ERROR! flexcompile.$HOST.$$" $USER <flexcompile
     67  mail -s "ERROR! flexcompile.$${HOST}.$$$$" $${USER} <flexcompile
    6868fi
Note: See TracChangeset for help on using the changeset viewer.
hosted by ZAMG