#!/bin/tcsh -fx
##########################################################################
#
# routine: bc_calncb.csh
#
# purpose: Tasks that preceed CALNICB
#
# modification history:
#
#   date    opr     who     reason
# -------- -----  --------  --------------------------------------
# 10/08/01 44598  MSwam     initial version
# 09/10/12 70213  MSwam     use tcsh
#
##########################################################################
set banner=">>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>"
echo $banner
\date
#
set go_absent = 102          #this exit status is in the FATAL range for XPOLL
set all_is_well = 1
#
# parse dataset,userid from OSF field
set expname = $OSF_DATASET
#
#-------------------------------------------------------
# resolve stretch for UNIX
#-------------------------------------------------------
set caldir = `osfile_stretch_file $OUTPATH`
set sisdir = `osfile_stretch_file $INPATH`
#
#-------------------------------------------------------
# check for directories
#-------------------------------------------------------
if (! -e $caldir) then
   echo "ERROR: $caldir directory does not exist"
   echo $banner
   exit $go_absent
endif
if (! -e $sisdir) then
   echo "ERROR: $sisdir directory does not exist"
   echo $banner
   exit $go_absent
endif

exit $all_is_well
