#!/bin/sh set -xa #################################### # Specify NET and RUN Name and model #################################### export NET=cfs export RUN=cfs export host=${host:-`hostname | cut -c1`} ############################################### # SETUP CDAS POST PROCESSING VARIABLES ############################################### export PS4='$SECONDS + ' date ########################################################## export DATA=${DATA:-${DATAROOT:?}/${jobid:?}} mkdir -p $DATA cd $DATA #################################### # Determine Job Output Name on System #################################### export pgmout="OUTPUT.$$" export pgmerr=errfile export cycle=t${cyc}z ############################## # Run setpdy and initialize PDY variables ############################## sh setpdy.sh . ./PDY ########################################################## # define cfs directories/scripts/executables ########################################################## export EXECcfs=$HOMEcfs/exec export PARMcfs=$HOMEcfs/parm export USHcfs=$HOMEcfs/ush export FIXcfs=$HOMEcfs/fix ############################################## # Define COM directories ############################################## export COMROT=$(compath.py -o ${NET}/${cfs_ver}) export COMIN=$(compath.py -o ${NET}/${cfs_ver}/${RUN}.${PDY}) env ############################### # Execute the Script ############################### ${CFSCLEANUPSH:-$HOMEcfs/scripts/excfs_cleanup.sh} err=$?; err_chk cat $pgmout msg="ENDED NORMALLY." postmsg "$msg" ######################################## # Remove the Temporary working directory ######################################## cd $DATAROOT if [ ${KEEPDATA:-NO} = NO ] ; then rm -rf $DATA ; fi date