#! /bin/csh -f
#
#   convert a bunch of miriad datasets into nemo (and fits)
#
#   24-feb-2010    Original written 

if ($#argv == 0) then
  echo "Usage: $0 miriad_file(s)"
  echo This script will populate each listed miriad image with a fits and nemo item
  exit 0
endif

foreach d ($*)
   if (-f $d/image) then
     fits     in=$d      out=$d/fits op=xyout
     fitsccd  in=$d/fits out=$d/nemo
   else
     echo "Skipping $d : no image found, not a miriad image dataset ?"
   endif
end
