Changeset 1920
- Timestamp:
- 11/13/12 19:24:54 (12 years ago)
- Location:
- TOOLS/PACK_IPSL
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
TOOLS/PACK_IPSL/DEM_utilities.sh
r1911 r1920 81 81 # Calcul du minimum d'un nombre quelconque d'entiers 82 82 local l_min=${1} l_xx 83 83 84 84 for l_xx in ${*:2:${#}} 85 85 do 86 [[ ${l_xx} -lt ${l_min} ]] && l_min=${l_xx} 86 l_xx_tmp=`echo $l_xx|sed 's/^0*//'` 87 l_min_tmp=`echo $l_min|sed 's/^0*//'` 88 [[ ${l_xx_tmp} -lt ${l_min_tmp} ]] && l_min=${l_xx} 87 89 done 88 90 echo ${l_min} … … 95 97 for l_xx in ${*:2:${#}} 96 98 do 97 [[ ${l_xx} -gt ${l_max} ]] && l_max=${l_xx} 99 l_xx_tmp=`echo $l_xx|sed 's/^0*//'` 100 l_max_tmp=`echo $l_max|sed 's/^0*//'` 101 [[ ${l_xx_tmp} -gt ${l_max_tmp} ]] && l_max=${l_xx} 98 102 done 99 103 echo ${l_max} -
TOOLS/PACK_IPSL/find_size_pack.sh
r1900 r1920 147 147 148 148 DEM_log -2 "Entree boucle : year_begin_pack month_begin_pack year_end_pack month_end_pack : ${year_begin_pack} ${month_begin_pack} ${year_end_pack} ${month_end_pack}" 149 150 149 # on travaille pour chaque type de fichiers 151 150 for type_file in `awk '{print $0}' ${IGCM_DEM_SIMU}/info_name_file.txt` … … 178 177 done 179 178 # on fait la somme par periodpack et par type de fichier de la taille qu'aurait le pack 180 awk 'BEGIN {y = 0} {x = $1 ; y = y + x } END{print y}' ${IGCM_TMP}/${$}.info_${type_file}_${number_pack}.txt >> ${IGCM_TMP}/${$}.size_pack_${type_file}.txt 181 [[ "${clean_tmp}" = "yes" ]] && rm -f ${IGCM_TMP}/${$}.info_${type_file}_${number_pack}.txt 179 if [ -f ${IGCM_TMP}/${$}.info_${type_file}_${number_pack}.txt ] 180 then 181 awk 'BEGIN {y = 0} {x = $1 ; y = y + x } END{print y}' ${IGCM_TMP}/${$}.info_${type_file}_${number_pack}.txt >> ${IGCM_TMP}/${$}.size_pack_${type_file}.txt 182 [[ "${clean_tmp}" = "yes" ]] && rm -f ${IGCM_TMP}/${$}.info_${type_file}_${number_pack}.txt 183 fi 182 184 done 183 185
Note: See TracChangeset
for help on using the changeset viewer.