/[MITgcm]/MITgcm/tools/example_scripts/csail/test_dickens
ViewVC logotype

Diff of /MITgcm/tools/example_scripts/csail/test_dickens

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

revision 1.7 by jmc, Tue Jun 2 17:08:48 2009 UTC revision 1.11 by jmc, Fri Jun 26 16:51:23 2009 UTC
# Line 9  Line 9 
9    
10  # defaults  # defaults
11  export PATH="$PATH:/usr/local/bin"  export PATH="$PATH:/usr/local/bin"
12    #- to get case insensitive "ls" (and order of tested experiments)
13    export LC_ALL="en_US.UTF-8"
14    #  Turn off stack limit for FIZHI & AD-tests
15    ulimit -s unlimited
16    
17  TESTDIR="/tmp/jmc/test_"`hostname -s`  TESTDIR="/tmp/jmc/test_"`hostname -s`
18  MC=10  MC=10
19  checkOut=1  checkOut=1
20  sepDir=0  sepDir=0
21    option=
22  #tst_list='adm g77 pgi gfo ifc mth'  #tst_list='adm g77 pgi gfo ifc mth'
23  tst_list='adm g77 gfo+rs mth'  tst_list='adm g77 gfo+rs mth'
24    
25  #  Turn off stack limit for FIZHI  #option="-nc" ; checkOut=0
26  ulimit -s unlimited  #option="-q"  ; checkOut=0
27    
28  tdir=$TESTDIR  tdir=$TESTDIR
29  if test $checkOut = '0' ; then  if test $checkOut = '0' ; then
# Line 25  if test $checkOut = '0' ; then Line 31  if test $checkOut = '0' ; then
31    echo $tdir/MITgcm/CVS 'exist'    echo $tdir/MITgcm/CVS 'exist'
32    echo -n "Update the MITgcm code from CVS pserver..."    echo -n "Update the MITgcm code from CVS pserver..."
33    cd $tdir/MITgcm    cd $tdir/MITgcm
34    cvs -d :pserver:cvsanon@mitgcm.org:/u/gcmpack update -P -d > /dev/null    if test $sepDir = 1 ; then
35       cvs -d :pserver:cvsanon@mitgcm.org:/u/gcmpack update -P -d > /dev/null
36      else
37       cvs -d :pserver:cvsanon@mitgcm.org:/u/gcmpack update -P -d
38      fi
39    echo "  done"    echo "  done"
40    cd $tdir   else
  else  
41    echo -n $tdir/MITgcm 'missing ; '    echo -n $tdir/MITgcm 'missing ; '
42    checkOut=1    checkOut=1
43   fi   fi
# Line 48  if test $checkOut = '1' ; then Line 57  if test $checkOut = '1' ; then
57   #cvs co -P MITgcm > /dev/null   #cvs co -P MITgcm > /dev/null
58    cvs -d :pserver:cvsanon@mitgcm.org:/u/gcmpack co -P MITgcm > /dev/null    cvs -d :pserver:cvsanon@mitgcm.org:/u/gcmpack co -P MITgcm > /dev/null
59    echo "  done"    echo "  done"
60    else
61      cd $tdir
62  fi  fi
63    
64  #------------------------------------------------------------------------  #------------------------------------------------------------------------
65    
66    firstTst=`echo $tst_list | awk '{print $1}'`
67    last_Tst=`echo $tst_list | awk '{print $NF}'`
68  for tt in $tst_list  for tt in $tst_list
69  do  do
70    
# Line 61  do Line 74  do
74   rm -f $tdir/output_${typ}*   rm -f $tdir/output_${typ}*
75   if test $sepDir = 1 ; then   if test $sepDir = 1 ; then
76    new_dir="MITgcm_$typ"    new_dir="MITgcm_$typ"
77    test -e $new_dir  &&  rm -rf $new_dir    if test -d $new_dir/CVS -a $checkOut = '0' ; then
78    mkdir $new_dir      pushd $new_dir
79    pushd $new_dir      echo -n "Update the MITgcm code from CVS pserver..."
80    cp -ra ../MITgcm/* .      cvs -d :pserver:cvsanon@mitgcm.org:/u/gcmpack update -P -d
81        echo "  done"
82      else
83        test -e $new_dir  &&  rm -rf $new_dir
84        mkdir $new_dir
85        pushd $new_dir
86        cp -ra ../MITgcm/* .
87      fi
88   else   else
89    pushd MITgcm    pushd MITgcm
90   fi   fi
# Line 81  do Line 101  do
101     *) OPTFILE= ;;     *) OPTFILE= ;;
102   esac   esac
103    
104     if test $sepDir = 0 -a $checkOut = '1' -a  $tt = $firstTst ; then
105    #-- cleaning:
106      echo "======================"
107      echo "Cleaning test directories:"
108        cmdCLN="./testreport -clean"
109        echo " clean dir running: $cmdCLN"
110        $cmdCLN > /dev/null 2>&1
111      echo "======================"
112      echo
113     fi
114    
115   if test $typ = 'g77'   if test $typ = 'g77'
116   then   then
117    
# Line 89  do Line 120  do
120    if test "x$OPTFILE" != x ; then    if test "x$OPTFILE" != x ; then
121      comm="$comm -of=$OPTFILE"      comm="$comm -of=$OPTFILE"
122    fi    fi
123      if test "x$option" != x ; then comm="$comm $option" ; fi
124    echo "  \"$comm\""    echo "  \"$comm\""
125    echo "======================"    echo "======================"
126    $comm > $tdir/output_$typ 2>&1    $comm > $tdir/output_$typ 2>&1
# Line 117  do Line 149  do
149    if test "x$OPTFILE" != x ; then    if test "x$OPTFILE" != x ; then
150      comm="$comm -of=$OPTFILE"      comm="$comm -of=$OPTFILE"
151    fi    fi
152      if test "x$option" != x ; then comm="$comm $option" ; fi
153    echo "  \"$comm\""    echo "  \"$comm\""
154    echo "======================"    echo "======================"
155    $comm > $tdir/output_$typ 2>&1    $comm > $tdir/output_$typ 2>&1
# Line 145  do Line 178  do
178    if test "x$OPTFILE" != x ; then    if test "x$OPTFILE" != x ; then
179      comm="$comm -of=$OPTFILE"      comm="$comm -of=$OPTFILE"
180    fi    fi
181      if test "x$option" != x ; then comm="$comm $option" ; fi
182    echo "  \"$comm\""    echo "  \"$comm\""
183    echo "======================"    echo "======================"
184    $comm > $tdir/output_$typ 2>&1    $comm > $tdir/output_$typ 2>&1
# Line 161  do Line 195  do
195    if test "x$OPTFILE" != x ; then    if test "x$OPTFILE" != x ; then
196      comm="$comm -of=$OPTFILE"      comm="$comm -of=$OPTFILE"
197    fi    fi
198      if test "x$option" != x ; then comm="$comm $option" ; fi
199    echo "  \"$comm\""    echo "  \"$comm\""
200    echo "======================"    echo "======================"
201    $comm > $tdir/output_$typ 2>&1    $comm > $tdir/output_$typ 2>&1
# Line 190  do Line 225  do
225    if test "x$OPTFILE" != x ; then    if test "x$OPTFILE" != x ; then
226      comm="$comm -of=$OPTFILE"      comm="$comm -of=$OPTFILE"
227    fi    fi
228      if test "x$option" != x ; then comm="$comm $option" ; fi
229    echo "  \"$comm\""    echo "  \"$comm\""
230    echo "======================"    echo "======================"
231    $comm > $tdir/output_$typ 2>&1    $comm > $tdir/output_$typ 2>&1
# Line 220  do Line 256  do
256    if test "x$OPTFILE" != x ; then    if test "x$OPTFILE" != x ; then
257      comm="$comm -of=$OPTFILE"      comm="$comm -of=$OPTFILE"
258    fi    fi
259      if test "x$option" != x ; then comm="$comm $option" ; fi
260    echo "  \"$comm\""    echo "  \"$comm\""
261    echo "======================"    echo "======================"
262    $comm > $tdir/output_${typ}_1 2>&1    $comm > $tdir/output_${typ}_1 2>&1
# Line 259  do Line 296  do
296      echo " clean tst_2+2 running: $cmdCLN"      echo " clean tst_2+2 running: $cmdCLN"
297      $cmdCLN >> $tdir/output_2+2 2>&1      $cmdCLN >> $tdir/output_2+2 2>&1
298    fi    fi
299      if test $tt != $last_Tst ; then
300      cmdCLN="./testreport -clean"      cmdCLN="./testreport -clean"
301      echo " clean dir running: $cmdCLN"      echo " clean dir running: $cmdCLN"
302      $cmdCLN > /dev/null 2>&1      $cmdCLN > /dev/null 2>&1
303      fi
304    echo "======================"    echo "======================"
305    echo    echo
306   fi   fi

Legend:
Removed from v.1.7  
changed lines
  Added in v.1.11

  ViewVC Help
Powered by ViewVC 1.1.22