Back to home page

MITgcm

 
 

    


Warning, /verification/cfc_example/input/prepare_run is written in an unsupported language. File is not indexed.

view on githubraw file Latest commit add29e06 on 2018-01-31 20:35:05 UTC
2f7ff84425 Jean*0001 #! /usr/bin/env bash
                0002 
                0003 #- in order to save disc space, take *.bin files
                0004 #- a) from this dir:
                0005 fromDir="../../tutorial_global_oce_biogeo/input"
                0006 
4bab883c23 Jean*0007 fileList=`( cd $fromDir ; ls *.bin | grep -v 'sillev1.bin' | grep -v 'bathy.bin' )`
2f7ff84425 Jean*0008 
                0009 #echo 'fileList=' $fileList
                0010 
                0011 #- and do a symbolic link in the current directory 
                0012 #   (if the file does not already exist)
                0013 if test -d $fromDir ; then
                0014   lnkList='files:'
                0015   for xx in $fileList
                0016   do
                0017     if test -r ${fromDir}/$xx ; then 
                0018       if test ! -r $xx ; then 
                0019         lnkList=${lnkList}" "$xx
                0020         ln -sf ${fromDir}/$xx .
                0021       fi
                0022     fi
                0023   done
                0024   echo ' link' $lnkList "from dir:" $fromDir
                0025 else
                0026   echo " Error:" $fromDir "not a directory"
                0027 fi
                0028 
                0029 #- and b) from this dir:
                0030 fromDir="../../tutorial_cfc_offline/input"
                0031 
4bab883c23 Jean*0032 fileList=`( cd $fromDir ; ls pickup*.0004269600* *.bin )`
2f7ff84425 Jean*0033 
                0034 #- and do a symbolic link in the current directory 
                0035 #   (if the file does not already exist)
                0036 if test -d $fromDir ; then
                0037   lnkList='files:'
                0038   for xx in $fileList
                0039   do
                0040     if test -r ${fromDir}/$xx ; then 
                0041       if test ! -r $xx ; then 
                0042         lnkList=${lnkList}" "$xx
                0043         ln -sf ${fromDir}/$xx .
                0044       fi
                0045     fi
                0046   done
                0047   echo ' link' $lnkList "from dir:" $fromDir
                0048 else
                0049   echo " Error:" $fromDir "not a directory"
                0050 fi