Changeset 672


Ignore:
Timestamp:
06/26/09 12:20:34 (15 years ago)
Author:
sdipsl
Message:
  • Adapt this part to 39 levels (ie .resol can have 2 lines)
File:
1 edited

Legend:

Unmodified
Added
Removed
  • modipsl/trunk/util/ins_job

    r379 r672  
    114114  } 
    115115 # We keep explicitly JobName because it is not optionnal. 
    116  RESOL=this_is_a_test_string 
     116 RESOL_ATM_3D=this_is_a_test_string 
     117 RESOL=this_is_another_test_string 
    117118 IGCM_card_DefineVariableFromOption ${j}'/'${F_CFG} UserChoices JobName 
    118  if [ ! X$( echo ${config_UserChoices_JobName} | grep ${RESOL} ) = X ] ; then  
    119     TRUERESOL=$( find ../ -name ".resol" -exec cat {} \; ) 
    120     config_UserChoices_JobName=$( echo ${config_UserChoices_JobName} | sed -e "s/${RESOL}/${TRUERESOL}/" ) 
     119 if [ ! X$( echo ${config_UserChoices_JobName} | grep ${RESOL_ATM_3D} ) = X ] ; then 
     120    TRUERESOL=$( find ../ -name ".resol" -exec tail -1 {} \; | awk "-F=" '{print $2}' ) 
     121    config_UserChoices_JobName=$( echo ${config_UserChoices_JobName} | sed -e "s/${RESOL_ATM_3D}/${TRUERESOL}/" ) 
    121122    IGCM_card_WriteOption ${j}'/'${F_CFG} UserChoices JobName ${config_UserChoices_JobName} 
     123 else 
     124    if [ ! X$( echo ${config_UserChoices_JobName} | grep ${RESOL} ) = X ] ; then 
     125            TRUERESOL=$( find ../ -name ".resol" -exec head -1 {} \; ) 
     126            config_UserChoices_JobName=$( echo ${config_UserChoices_JobName} | sed -e "s/${RESOL}/${TRUERESOL}/" ) 
     127            IGCM_card_WriteOption ${j}'/'${F_CFG} UserChoices JobName ${config_UserChoices_JobName} 
     128    fi 
    122129 fi 
    123130  
Note: See TracChangeset for help on using the changeset viewer.