#!/bin/bash ######################################## # WAFS GRIB2 0P25 PRODUCT GENERATION ######################################## date export PS4='$SECONDS + ' set -x #################################### # make temp directory #################################### export DATA=${DATA:-${DATAROOT}/${jobid:?}} mkdir -p "${DATA}" && cd "${DATA}" ########################################### # Run setpdy and initialize PDY variables ########################################### export cycle=${cycle:-"t${cyc}z"} setpdy.sh . ./PDY #################################### # SEND to COM, DBN, etc #################################### export SENDCOM=${SENDCOM:-"YES"} export SENDDBN=${SENDDBN:-"YES"} #################################### # Specify NET and RUN Name and model #################################### export NET=${NET:-wafs} export RUN=${RUN:-wafs} ############################################## # Define COM directories ############################################## export COMINgfs=${COMINgfs:-$(compath.py "${envir}/gfs/${gfs_ver}")"/gfs.${PDY}/${cyc}/atmos"} export COMIN=${COMIN:-$(compath.py "${envir}/${NET}/${wafs_ver}")"/${RUN}.${PDY}/${cyc}/upp"} export COMOUT=${COMOUT:-$(compath.py -o "${NET}/${wafs_ver}")"/${RUN}.${PDY}/${cyc}/grib2/0p25"} mkdir -p "${COMOUT}" #################################### # Determine Job Output Name on System #################################### export pgmout="OUTPUT.$$" #################################### # Specify Execution Areas #################################### export FIXwafs="${HOMEwafs}/fix" ######################################################### # print current environment ######################################################### env ############################################ # Execute the script. ############################################ "${HOMEwafs}/scripts/exwafs_grib2_0p25.sh" export err=$? err_chk if [[ -e "${pgmout}" ]]; then cat "${pgmout}" fi ############################## # Remove the Temporary working directory ############################## if [[ "${KEEPDATA^^}" != "YES" ]]; then rm -rf "${DATA}" fi date