#!/bin/csh -f
#---------------------------------------------------------------------------
#
# Name: xp_sti_edt2dc
#
# Purpose: runs the SS,DV,WC,DC stages for STIS under OWL
#            (STIS does DC before GC, so it can't use the edt2fits
#             task.  It's the only instrument that does this.)
#
# Args: pathname ($1)   = pathname to process under
# Args: dataset ($2)    = name of dataset to process
#
# History:
# 07/10/12  71706  MSwam         first version
#---------------------------------------------------------------------------
set PATHNAME   = $1
set DATASET    = $2
#
ss_SupportSchedule -r ss_sti -p ${PATHNAME} ${DATASET}
if ($status != 0) then
   echo "SS FAILED."
   exit 1
endif
dv_DataValidation -r dv_sti -p ${PATHNAME} ${DATASET}
if ($status != 0) then
   echo "DV FAILED."
   exit 1
endif
wcs_WorldCoordinates -r wcstis -p ${PATHNAME} ${DATASET}
if ($status != 0) then
   echo "WC FAILED."
   exit 1
endif
dc_DataCollector -r dc_sti -p ${PATHNAME} ${DATASET}
if ($status != 0) then
   echo "DC FAILED."
   exit 1
endif
exit 0
