My apologies, this question slipped through the cracks. This is
something you can't currently do with NCL, but it has been on our
list of enhancements we'd like to make.
Bob found a solution, which I thought was pretty clever:
   At the top of the ncl script:   system("touch abnormal_exit")
   at the end of the ncl script:   system("\rm abnormal_exit")
   and in the c-shell script after the ncl script runs:
       if !(-e abnormal_ext) then
          tell me
          exit
       endif
--Mary
On Fri, 2 Jun 2006, Bob Tomas wrote:
> Hello
>
> I have a c-shell script that does a number of things including running an ncl 
> script.  I'd like to exit the c-shell script if the ncl script doesn't
> complete normally.  I tried this:
>
>
> 	ncl script_name.ncl || exit 1
>
>
> and
>
> 	ncl script_name.ncl || exit 1
> 	if($status != 0) then
>           exit 1
>        endif
>
> but these methods don't work.  Is there some other way to simply do what
> I want?
>
> Thanks.
>
> Bob
> -- 
> -------------------------------------------------------------
> Robert A. Tomas
> National Center for Atmospheric Research
> Climate and Global Dynamics Division - Paleoclimatology
> 1850 Table Mesa Drive
> Boulder, CO 80305-3000
> e-mail: tomas_at_ucar.edu  tel: 303-497-1342  fax:  303-497-1348
> _______________________________________________
> ncl-talk mailing list
> ncl-talk_at_ucar.edu
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
_______________________________________________
ncl-talk mailing list
ncl-talk_at_ucar.edu
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Thu Jun 08 2006 - 13:17:25 MDT
This archive was generated by hypermail 2.2.0 : Thu Jun 08 2006 - 13:18:44 MDT