Merge pull request #22 from wirc-sjsu/develop-w21
[WRF-Fire-merge.git] / test / em_fire / restart / regtest_restart.csh
blobcb628eac7d27c4a820f5bd209b11ed17d58b77a5
1 #!/bin/csh -f
2 echo usage: $0 wrf.exe or something like $0 mpirun -np 5 wrf.exe for a parallel run
3 setenv CMD "$*"
4 setenv DIFFWRF ../../../external/io_netcdf/diffwrf
5 setenv NLISTV namelist.input.var
6 setenv DIR _regtest_restart_tmp.dir
7 setenv WRFRST1 wrfrst_d01_0001-01-01_00:01:00
8 setenv WRFRST5 wrfrst_d01_0001-01-01_00:02:00
10 echo complete run
12 cat $NLISTV | sed 's/RESTART/\.false\./' | sed 's/START_M/00/g' > namelist.input
14 rm -rf wrfrst_* wrfout_* rsl.* > /dev/null
16 ./ideal.exe
18 $CMD
19 if ($status) then
20 exit(1)
21 endif
23 rm -rf $DIR > /dev/null ; mkdir $DIR
24 mv wrfrst_* wrfout_* rsl.* $DIR
26 echo restart run
28 cat $NLISTV | sed 's/RESTART/\.true\./' | sed 's/START_M/01/g' > namelist.input
29 cp $DIR/$WRFRST1 .
30 $CMD
31 if ($status) then
32 exit(1)
33 endif
35 $DIFFWRF $WRFRST5 $DIR/$WRFRST5 | grep -v '^ *TS_'