if [ -n "$BATCHMODE" ] then fileList='ad_input_code.w2f.canon.xb.x2w.w2f.rs.pp.f all_mods.xb.x2w.w2f.pp.f m.out' else fileList='ad_input_code_sf.f ad_input_code_sf.w2f.f ad_input_code_sf.w2f.canon.f ad_input_code_sf.w2f.canon.xaif ad_input_code_sf.w2f.canon.xb.xaif ad_input_code_sf.w2f.canon.xb.x2w.w2f.f ad_input_code_sf.w2f.canon.xb.x2w.w2f.rs.f ad_input_code_sf.w2f.canon.xb.x2w.w2f.rs.pp.f ad_input_code.w2f.canon.xb.x2w.w2f.rs.pp.f all_mods.xb.x2w.w2f.pp.f m.out' fi for i in `echo ${fileList}` do gunzip -c ${i}.gz > ${i} echo "$i old reference (<) vs new file (>)" echo "------------------------------------------------------------------------------" diff -i -I "file translated from " $i ../../../../../MITgcm/verification/OpenAD/build_shallow_openad3/$i if [ $? -ne 0 -a -z "$BATCHMODE" ] then echo "update reference for $i? [y]/n " read answer if [ "$answer" == "n" ] then echo "not updated" else echo "copying" cp ../../../../../MITgcm/verification/OpenAD/build_shallow_openad3/$i $i gzip -f ${i} fi fi done