Commit 0cd08a07 authored by dumoda01's avatar dumoda01

Ajout de script batch_???.sh pour differentes applications.

parent e69ad1fa
#!/bin/bash
export EXPDIR=$(pwd)
echo $EXPDIR
if [ ! airsea.mal ] || [ ! gotmrun.mal ]
then
echo " ERROR : .mal files missing"
exit
else
echo "-----------------------------------------------------"
echo " batch_airsea.sh"
echo "-----------------------------------------------------"
# Parameters for the forcings
count=0
for file in narr_momentum_*.dat
do
count=`expr $count + 1`
count=`expr 000$count | tail -3c`
#count=`expr 000$count | tail -8c`
echo $count
if [ -f airsea.nml ]
then
rm -f airsea.nml
fi
cat airsea.mal | sed \
-e "s/heatfile/narr_heatflux_2008_$count/g" \
> airsea.nml
if [ -f airsea.nml ]
then
echo " airsea.nml created"
fi
if [ -f gotmrun.nml ]
then
rm -f gotmrun.nml
fi
cat gotmrun.mal | sed \
-e "s/experiment_name/$count/g" \
> gotmrun.nml
if [ -f gotmrun.nml ]
then
echo " gotmrun.nml created"
fi
strt=`date +%H:%M:%S`
echo " started at "$strt
#./gotm_prod_IFORT >& $count.out
end=`date +%H:%M:%S`
echo " ended at "$end
done
fi
exit
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment