diff --git a/CMakeLists.txt b/CMakeLists.txt index a7e25d98..42f35741 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -27,6 +27,7 @@ set (programs scm_setup gcm_quickstat.j scm_run.j + construct_extdata_yaml_list.py ) install ( diff --git a/construct_extdata_yaml_list.py b/construct_extdata_yaml_list.py new file mode 100755 index 00000000..95d50d68 --- /dev/null +++ b/construct_extdata_yaml_list.py @@ -0,0 +1,87 @@ +#!/usr/bin/env python3 +import yaml +import argparse +import os + +def parse_args(): + p = argparse.ArgumentParser(description='create extdata master file') + p.add_argument('rc_file',type=str,help='GEOS_ChemGridComp.rc file') + return vars(p.parse_args()) + +if __name__ == '__main__': + + args = parse_args() + rc_file = args['rc_file'] + + f = open(rc_file,"r") + temp_text = f.readlines() + f.close() + + component_yaml_files = yaml.safe_load(""" + GOCART: + - CFC_GridComp_ExtData.yaml + - CH4_GridComp_ExtData.yaml + - CO2_GridComp_ExtData.yaml + - CO_GridComp_ExtData.yaml + - O3_GridComp_ExtData.yaml + - Rn_GridComp_ExtData.yaml + GOCART2G: + - CA2G_GridComp_ExtData.yaml + - DU2G_GridComp_ExtData.yaml + - NI2G_GridComp_ExtData.yaml + - SS2G_GridComp_ExtData.yaml + - SU2G_GridComp_ExtData.yaml + GAAS: + - GAAS_GridComp_ExtData.yaml + STRATCHEM: + - StratChem_ExtData.yaml + GMICHEM: + - GMI_ExtData.yaml + CARMA: + - CARMAchem_GridComp_ExtData.yaml + MAM: + - MAM7_ExtData.yaml + ACHEM: + - GEOSachem_ExtData.yaml + TR: + - TR_ExtData.yaml + DNA: + - DNA_ExtData.yaml + HEMCO: + - HEMCOgmi_ExtData.yaml + - HEMCOgocart2g_ExtData.yaml + Extras: + - ChemEnv_ExtData.yaml + - WSUB_ExtData.yaml + """) + components = {} + for line in temp_text: + if "ENABLE" in line: + entry = line.split(":") + if ".TRUE." in entry[1]: + component_on = True + if ".FALSE." in entry[1]: + component_on = False + key_name = entry[0] + component_name = key_name.replace("ENABLE_","") + component_name = component_name.lstrip() + components[component_name] = component_on + + files_to_use = [] + for key in components: + if key in component_yaml_files and components[key]: + files = component_yaml_files[key] + for single_file in files: + files_to_use.append(single_file) + + extra_files = component_yaml_files["Extras"] + for single_file in extra_files: + files_to_use.append(single_file) + + f = open("extdata.yaml","w") + f.write("subconfigs:\n") + for single_file in files_to_use: + f.write(" - "+single_file+"\n") + f.close() + + diff --git a/gcm_forecast.tmpl b/gcm_forecast.tmpl index 53397083..d028e746 100755 --- a/gcm_forecast.tmpl +++ b/gcm_forecast.tmpl @@ -598,28 +598,36 @@ endif set yearc = `echo $nymdc | cut -c1-4` set yearf = `echo $nymdf | cut -c1-4` +# Which ExtData are we using +set EXTDATA2G_TRUE = `grep -i '^\s*USE_EXTDATA2G:\s*\.TRUE\.' CAP.rc | wc -l + # Select proper AMIP GOCART Emission RC Files # ------------------------------------------- if( ${EMISSIONS} == AMIP_EMISSIONS) then set AMIP_Transition_Date = 20000301 - - if( $nymdc < ${AMIP_Transition_Date} ) then - set AMIP_EMISSIONS_DIRECTORY = $EXPDIR/RC/AMIP.20C - if( $nymdf > ${AMIP_Transition_Date} ) then - set nymdf = ${AMIP_Transition_Date} - set oldstring = `grep '^\s*END_DATE:' CAP.rc` - set newstring = "END_DATE: $nymdf $nhmsf" - /bin/mv CAP.rc CAP.tmp - cat CAP.tmp | sed -e "s?$oldstring?$newstring?g" > CAP.rc - endif + if( $EXTDATA2G_TRUE == 0 ) then + if( $nymdc < ${AMIP_Transition_Date} ) then + set AMIP_EMISSIONS_DIRECTORY = $EXPDIR/RC/AMIP.20C + if( $nymdf > ${AMIP_Transition_Date} ) then + set nymdf = ${AMIP_Transition_Date} + set oldstring = `grep '^\s*END_DATE:' CAP.rc` + set newstring = "END_DATE: $nymdf $nhmsf" + /bin/mv CAP.rc CAP.tmp + cat CAP.tmp | sed -e "s?$oldstring?$newstring?g" > CAP.rc + endif + else + set AMIP_EMISSIONS_DIRECTORY = $EXPDIR/RC/AMIP + endif else - set AMIP_EMISSIONS_DIRECTORY = $EXPDIR/RC/AMIP + set AMIP_EMISSIONS_DIRECTORY = $EXPDIR/RC/AMIP endif + if( $AGCM_LM == 72 ) then cp ${AMIP_EMISSIONS_DIRECTORY}/*.rc . + cp ${AMIP_EMISSIONS_DIRECTORY}/*.yaml . else - set files = `/bin/ls -1 ${AMIP_EMISSIONS_DIRECTORY}/*.rc` + set files = `/bin/ls -1 ${AMIP_EMISSIONS_DIRECTORY}/*.rc ${AMIP_EMISSIONS_DIRECTORY}/*.yaml` foreach file ($files) /bin/rm -f `basename $file` /bin/rm -f dummy @@ -655,8 +663,13 @@ if ( $GOCART_DATA_TRUE == 0 && -e GOCARTdata_ExtData.rc ) /bin/mv @MP_NO_USE_WSUB# 1MOM and GFDL microphysics do not use WSUB_NATURE @MP_NO_USE_WSUB# ------------------------------------------------- -@MP_NO_USE_WSUB/bin/mv WSUB_ExtData.rc WSUB_ExtData.tmp -@MP_NO_USE_WSUBcat WSUB_ExtData.tmp | sed -e '/^WSUB_NATURE/ s#ExtData.*#/dev/null#' > WSUB_ExtData.rc +if ($EXTDATA2G_TRUE == 0 ) then + @MP_NO_USE_WSUB/bin/mv WSUB_ExtData.rc WSUB_ExtData.tmp + @MP_NO_USE_WSUBcat WSUB_ExtData.tmp | sed -e '/^WSUB_NATURE/ s#ExtData.*#/dev/null#' > WSUB_ExtData.rc +else + @MP_NO_USE_WSUB/bin/mv WSUB_ExtData.yaml WSUB_ExtData.tmp + @MP_NO_USE_WSUBcat WSUB_ExtData.tmp | sed -e '/collection:/ s#WSUB_Wvar_positive_05hrdeg.*#/dev/null#' > WSUB_ExtData.yaml +endif @MP_NO_USE_WSUB/bin/rm WSUB_ExtData.tmp # Generate the complete ExtData.rc @@ -665,11 +678,20 @@ if(-e ExtData.rc ) /bin/rm -f ExtData.rc set extdata_files = `/bin/ls -1 *_ExtData.rc` # Switch to MODIS v6.1 data after Nov 2021 -set MODIS_Transition_Date = 20211101 -if ( ${EMISSIONS} == OPS_EMISSIONS && ${MODIS_Transition_Date} <= $nymdc ) then - cat $extdata_files | sed 's|\(qfed2.emis_.*\).006.|\1.061.|g' > ExtData.rc -else - cat $extdata_files > ExtData.rc +if( $EXTDATA2G_TRUE == 0 ) then + set MODIS_Transition_Date = 20211101 + if ( ${EMISSIONS} == OPS_EMISSIONS && ${MODIS_Transition_Date} <= $nymdc ) then + cat $extdata_files | sed 's|\(qfed2.emis_.*\).006.|\1.061.|g' > ExtData.rc + else + cat $extdata_files > ExtData.rc + endif +endif + +if( $EXTDATA2G_TRUE == 1 ) then + + $GEOSBIN/construct_extdata_yaml_list.py GEOS_ChemGridComp.rc + touch ExtData.rc + endif # Move GOCART to use RRTMGP Bands diff --git a/gcm_regress.j b/gcm_regress.j index 938e708e..056f0263 100755 --- a/gcm_regress.j +++ b/gcm_regress.j @@ -69,6 +69,7 @@ cd $HOMDIR cd $EXPDIR/regress cp $EXPDIR/RC/*.rc $EXPDIR/regress +cp $EXPDIR/RC/*.yaml $EXPDIR/regress cp $EXPDIR/GEOSgcm.x $EXPDIR/regress cp $EXPDIR/linkbcs $EXPDIR/regress cp $HOMDIR/*.yaml $EXPDIR/regress @@ -209,22 +210,29 @@ set date = `cat cap_restart` set nymd0 = $date[1] set nhms0 = $date[2] +set EXTDATA2G_TRUE = `grep -i '^\s*USE_EXTDATA2G:\s*\.TRUE\.' CAP.rc | wc -l` + # Select proper AMIP GOCART Emission RC Files # ------------------------------------------- setenv EMISSIONS @EMISSIONS if( @EMISSIONS == AMIP_EMISSIONS ) then - set AMIP_Transition_Date = 20000301 + if( $EXTDATA2G_TRUE == 0 ) then + set AMIP_Transition_Date = 20000301 - if( $nymd0 < ${AMIP_Transition_Date} ) then - set AMIP_EMISSIONS_DIRECTORY = $EXPDIR/RC/AMIP.20C + if( $nymd0 < ${AMIP_Transition_Date} ) then + set AMIP_EMISSIONS_DIRECTORY = $EXPDIR/RC/AMIP.20C + else + set AMIP_EMISSIONS_DIRECTORY = $EXPDIR/RC/AMIP + endif else - set AMIP_EMISSIONS_DIRECTORY = $EXPDIR/RC/AMIP + set AMIP_EMISSIONS_DIRECTORY = $EXPDIR/RC/AMIP endif if( $LM == 72 ) then cp ${AMIP_EMISSIONS_DIRECTORY}/*.rc . + cp ${AMIP_EMISSIONS_DIRECTORY}/*.yaml . else - set files = `/bin/ls -1 ${AMIP_EMISSIONS_DIRECTORY}/*.rc` + set files = `/bin/ls -1 ${AMIP_EMISSIONS_DIRECTORY}/*.rc ${AMIP_EMISSIONS_DIRECTORY}/*.yaml` foreach file ($files) /bin/rm -f `basename $file` /bin/rm -f dummy @@ -236,8 +244,13 @@ endif @MP_NO_USE_WSUB# 1MOM and GFDL microphysics do not use WSUB_NATURE @MP_NO_USE_WSUB# ------------------------------------------------- -@MP_NO_USE_WSUB/bin/mv WSUB_ExtData.rc WSUB_ExtData.tmp -@MP_NO_USE_WSUBcat WSUB_ExtData.tmp | sed -e '/^WSUB_NATURE/ s#ExtData.*#/dev/null#' > WSUB_ExtData.rc +if ($EXTDATA2G_TRUE == 0 ) then + @MP_NO_USE_WSUB/bin/mv WSUB_ExtData.rc WSUB_ExtData.tmp + @MP_NO_USE_WSUBcat WSUB_ExtData.tmp | sed -e '/^WSUB_NATURE/ s#ExtData.*#/dev/null#' > WSUB_ExtData.rc +else + @MP_NO_USE_WSUB/bin/mv WSUB_ExtData.yaml WSUB_ExtData.tmp + @MP_NO_USE_WSUBcat WSUB_ExtData.tmp | sed -e '/collection:/ s#WSUB_Wvar_positive_05hrdeg.*#/dev/null#' > WSUB_ExtData.yaml +endif @MP_NO_USE_WSUB/bin/rm WSUB_ExtData.tmp # Generate the complete ExtData.rc @@ -246,11 +259,20 @@ if(-e ExtData.rc ) /bin/rm -f ExtData.rc set extdata_files = `/bin/ls -1 *_ExtData.rc` # Switch to MODIS v6.1 data after Nov 2021 -set MODIS_Transition_Date = 20211101 -if ( ${EMISSIONS} == OPS_EMISSIONS && ${MODIS_Transition_Date} <= $nymd0 ) then - cat $extdata_files | sed 's|\(qfed2.emis_.*\).006.|\1.061.|g' > ExtData.rc -else - cat $extdata_files > ExtData.rc +if( $EXTDATA2G_TRUE == 0 ) then + set MODIS_Transition_Date = 20211101 + if ( ${EMISSIONS} == OPS_EMISSIONS && ${MODIS_Transition_Date} <= $nymd0 ) then + cat $extdata_files | sed 's|\(qfed2.emis_.*\).006.|\1.061.|g' > ExtData.rc + else + cat $extdata_files > ExtData.rc + endif +endif + +if( $EXTDATA2G_TRUE == 1 ) then + + $GEOSBIN/construct_extdata_yaml_list.py GEOS_ChemGridComp.rc + touch ExtData.rc + endif # Move GOCART to use RRTMGP Bands diff --git a/gcm_run.j b/gcm_run.j index 0ce85829..a00505ff 100755 --- a/gcm_run.j +++ b/gcm_run.j @@ -578,35 +578,43 @@ if( @OCEANtag != DE0360xPE0180 ) then endif endif +# Which ExtData are we using +set EXTDATA2G_TRUE = `grep -i '^\s*USE_EXTDATA2G:\s*\.TRUE\.' CAP.rc | wc -l` + # Select proper AMIP GOCART Emission RC Files # ------------------------------------------- if( ${EMISSIONS} == AMIP_EMISSIONS ) then - set AMIP_Transition_Date = 20000301 - - # Before 2000-03-01, we need to use AMIP.20C which has different - # emissions (HFED instead of QFED) valid before 2000-03-01. Note - # that if you make a change to anything in $EXPDIR/RC/AMIP or - # $EXPDIR/RC/AMIP.20C, you might need to make a change in the other - # directory to be consistent. Some files in AMIP.20C are symlinks to - # that in AMIP but others are not. - - if( $nymdc < ${AMIP_Transition_Date} ) then - set AMIP_EMISSIONS_DIRECTORY = $EXPDIR/RC/AMIP.20C - if( $nymdf > ${AMIP_Transition_Date} ) then - set nymdf = ${AMIP_Transition_Date} - set oldstring = `grep '^\s*END_DATE:' CAP.rc` - set newstring = "END_DATE: $nymdf $nhmsf" - /bin/mv CAP.rc CAP.tmp - cat CAP.tmp | sed -e "s?$oldstring?$newstring?g" > CAP.rc - endif + if( $EXTDATA2G_TRUE == 0 ) then + set AMIP_Transition_Date = 20000301 + + # Before 2000-03-01, we need to use AMIP.20C which has different + # emissions (HFED instead of QFED) valid before 2000-03-01. Note + # that if you make a change to anything in $EXPDIR/RC/AMIP or + # $EXPDIR/RC/AMIP.20C, you might need to make a change in the other + # directory to be consistent. Some files in AMIP.20C are symlinks to + # that in AMIP but others are not. + + if( $nymdc < ${AMIP_Transition_Date} ) then + set AMIP_EMISSIONS_DIRECTORY = $EXPDIR/RC/AMIP.20C + if( $nymdf > ${AMIP_Transition_Date} ) then + set nymdf = ${AMIP_Transition_Date} + set oldstring = `grep '^\s*END_DATE:' CAP.rc` + set newstring = "END_DATE: $nymdf $nhmsf" + /bin/mv CAP.rc CAP.tmp + cat CAP.tmp | sed -e "s?$oldstring?$newstring?g" > CAP.rc + endif + else + set AMIP_EMISSIONS_DIRECTORY = $EXPDIR/RC/AMIP + endif else - set AMIP_EMISSIONS_DIRECTORY = $EXPDIR/RC/AMIP + set AMIP_EMISSIONS_DIRECTORY = $EXPDIR/RC/AMIP endif if( $AGCM_LM == 72 ) then cp ${AMIP_EMISSIONS_DIRECTORY}/*.rc . + cp ${AMIP_EMISSIONS_DIRECTORY}/*.yaml . else - set files = `/bin/ls -1 ${AMIP_EMISSIONS_DIRECTORY}/*.rc` + set files = `/bin/ls -1 ${AMIP_EMISSIONS_DIRECTORY}/*.rc ${AMIP_EMISSIONS_DIRECTORY}/*.yaml` foreach file ($files) /bin/rm -f `basename $file` /bin/rm -f dummy @@ -636,21 +644,37 @@ if ( $GOCART_DATA_TRUE == 0 && -e GOCARTdata_ExtData.rc ) /bin/mv @MP_NO_USE_WSUB# 1MOM and GFDL microphysics do not use WSUB_NATURE @MP_NO_USE_WSUB# ------------------------------------------------- -@MP_NO_USE_WSUB/bin/mv WSUB_ExtData.rc WSUB_ExtData.tmp -@MP_NO_USE_WSUBcat WSUB_ExtData.tmp | sed -e '/^WSUB_NATURE/ s#ExtData.*#/dev/null#' > WSUB_ExtData.rc +if ($EXTDATA2G_TRUE == 0 ) then + @MP_NO_USE_WSUB/bin/mv WSUB_ExtData.rc WSUB_ExtData.tmp + @MP_NO_USE_WSUBcat WSUB_ExtData.tmp | sed -e '/^WSUB_NATURE/ s#ExtData.*#/dev/null#' > WSUB_ExtData.rc +else + @MP_NO_USE_WSUB/bin/mv WSUB_ExtData.yaml WSUB_ExtData.tmp + @MP_NO_USE_WSUBcat WSUB_ExtData.tmp | sed -e '/collection:/ s#WSUB_Wvar_positive_05hrdeg.*#/dev/null#' > WSUB_ExtData.yaml +endif @MP_NO_USE_WSUB/bin/rm WSUB_ExtData.tmp + + # Generate the complete ExtData.rc # -------------------------------- if(-e ExtData.rc ) /bin/rm -f ExtData.rc set extdata_files = `/bin/ls -1 *_ExtData.rc` # Switch to MODIS v6.1 data after Nov 2021 -set MODIS_Transition_Date = 20211101 -if ( ${EMISSIONS} == OPS_EMISSIONS && ${MODIS_Transition_Date} <= $nymdc ) then - cat $extdata_files | sed 's|\(qfed2.emis_.*\).006.|\1.061.|g' > ExtData.rc -else -cat $extdata_files > ExtData.rc +if( $EXTDATA2G_TRUE == 0 ) then + set MODIS_Transition_Date = 20211101 + if ( ${EMISSIONS} == OPS_EMISSIONS && ${MODIS_Transition_Date} <= $nymdc ) then + cat $extdata_files | sed 's|\(qfed2.emis_.*\).006.|\1.061.|g' > ExtData.rc + else + cat $extdata_files > ExtData.rc + endif +endif + +if( $EXTDATA2G_TRUE == 1 ) then + + $GEOSBIN/construct_extdata_yaml_list.py GEOS_ChemGridComp.rc + touch ExtData.rc + endif # Move GOCART to use RRTMGP Bands diff --git a/gcm_setup b/gcm_setup index 228aa262..47d1a26f 100755 --- a/gcm_setup +++ b/gcm_setup @@ -1774,14 +1774,14 @@ echo $GROUP > $HOME/.GROUProot # Copy Model Executable and RC Files to Experiment Directory ####################################################################### - mkdir -p $EXPDIR/RC +mkdir -p $EXPDIR/RC - # Copy over all files and subdirs in install/etc, keeping symlinks - cp -RP $GEOSDIR/etc/* $EXPDIR/RC +# Copy over all files and subdirs in install/etc, keeping symlinks +cp -RP $GEOSDIR/etc/* $EXPDIR/RC - # Remove templated files in RC as they are unneeded and confusing for experiments - rm -f $EXPDIR/RC/*.tmpl - rm -f $EXPDIR/RC/fvcore_layout.rc +# Remove templated files in RC as they are unneeded and confusing for experiments +rm -f $EXPDIR/RC/*.tmpl +rm -f $EXPDIR/RC/fvcore_layout.rc if ( $LINKX == "TRUE" ) then if ( -e $GEOSBIN/GEOSgcm.x ) ln -s $GEOSBIN/GEOSgcm.x $EXPDIR diff --git a/scm_run.j b/scm_run.j index cd6106a9..0c380aeb 100755 --- a/scm_run.j +++ b/scm_run.j @@ -4,7 +4,7 @@ #@BATCH_JOBNAME #@BATCH_GROUP -umask 022 +umask 022 limit stacksize unlimited setenv ARCH `uname` @@ -26,4 +26,6 @@ setenv EXPDIR @EXPDIR cd $EXPDIR +@EXTDATA2G $GEOSBIN/construct_extdata_yaml_list.py GEOS_ChemGridComp.rc + $RUN_CMD 1 ./GEOSgcm.x diff --git a/scm_setup b/scm_setup index c95e3e4e..73474441 100755 --- a/scm_setup +++ b/scm_setup @@ -91,6 +91,8 @@ usage () echo " Optional argument: " echo " --num_levels: number of levels (72, 71, 91, 132, 137, and 181 allowed)." echo + echo " --extdata2g: run with extdata2g" + echo echo } @@ -101,6 +103,7 @@ selected_case=NULL expdir=NULL account=NULL nlev=72 +use_extdata2g=FALSE while [ "${1+defined}" ] do @@ -125,6 +128,10 @@ do nlev=$1 shift ;; + "--extdata2g") + shift + use_extdata2g=TRUE + ;; "--help" | "-h") usage exit 0 @@ -423,19 +430,28 @@ mkdir -p $expdir/ExtData year=$(cat $expdir/cap_restart | cut -c1-4) -if [[ "$year" -lt "2000" ]] +if [[ $use_extdata2g == TRUE ]] then - echo "Before 2000, using AMIP.20C" - /bin/cp $INSTALLDIR/etc/AMIP.20C/*.rc $expdir + /bin/cp $INSTALLDIR/etc/*.yaml $expdir + /bin/cp $INSTALLDIR/etc/AMIP/*.yaml $expdir + /bin/mv $expdir/WSUB_ExtData.yaml $expdir/WSUB_ExtData.tmp + cat $expdir/WSUB_ExtData.tmp | sed -e '/collection:/ s#WSUB_Wvar_positive_05hrdeg.*#/dev/null#' > $expdir/WSUB_ExtData.yaml + /bin/rm $expdir/WSUB_ExtData.tmp else - echo "After 2000, using AMIP" - /bin/cp $INSTALLDIR/etc/AMIP/*.rc $expdir -fi + if [[ "$year" -lt "2000" ]] + then + echo "Before 2000, using AMIP.20C" + /bin/cp $INSTALLDIR/etc/AMIP.20C/*.rc $expdir + else + echo "After 2000, using AMIP" + /bin/cp $INSTALLDIR/etc/AMIP/*.rc $expdir + fi -# Turn off wsub as we are 1moment -/bin/mv $expdir/WSUB_ExtData.rc $expdir/WSUB_ExtData.tmp -cat $expdir/WSUB_ExtData.tmp | sed -e '/^WSUB_NATURE/ s#ExtData.*#/dev/null#' > $expdir/WSUB_ExtData.rc -/bin/rm $expdir/WSUB_ExtData.tmp + # Turn off wsub as we are 1moment + /bin/mv $expdir/WSUB_ExtData.rc $expdir/WSUB_ExtData.tmp + cat $expdir/WSUB_ExtData.tmp | sed -e '/^WSUB_NATURE/ s#ExtData.*#/dev/null#' > $expdir/WSUB_ExtData.rc + /bin/rm $expdir/WSUB_ExtData.tmp +fi /bin/cp $SCMDIR/general/* $expdir @@ -462,6 +478,7 @@ then padlev=${temp:(-${#digits})} $ISED "s/L72/L${nlev}/g" $expdir/*.rc + $ISED "s/L72/L${nlev}/g" $expdir/*.yaml $ISED "/AGCM_LM:/c\AGCM_LM: ${nlev}" $expdir/AGCM.rc $ISED "/AGCM.LM:/c\AGCM.LM: ${nlev}" $expdir/AGCM.rc @@ -477,13 +494,20 @@ fi /bin/ln -s $CHMDIR/g5gcm $expdir/ExtData /bin/ln -s $CHMDIR/chemistry $expdir/ExtData -if [[ -e $expdir/ExtData.rc ]] +if [[ $use_extdata2g == TRUE ]] then - /bin/rm -f $expdir/ExtData.rc -fi + echo "USE_EXTDATA2G: .true." >> $expdir/CAP.rc + EXTDATA2G="" +else + if [[ -e $expdir/ExtData.rc ]] + then + /bin/rm -f $expdir/ExtData.rc + fi -extdata_files=`/bin/ls -1 $expdir/*_ExtData.rc` -cat $extdata_files > $expdir/ExtData.rc + extdata_files=`/bin/ls -1 $expdir/*_ExtData.rc` + cat $extdata_files > $expdir/ExtData.rc + EXTDATA2G="# ONLY FOR ExtData2G" +fi # Handle scm_run.j @@ -510,6 +534,7 @@ s?@BATCH_TASKS?$BATCH_TASKS?g s?@BATCH_TIME?$BATCH_TIME?g s?@BATCH_GROUP?$BATCH_GROUP?g s?@BATCH_JOBNAME?$BATCH_JOBNAME?g +s?@EXTDATA2G?$EXTDATA2G?g EOF $ISED -f $expdir/sedfile $expdir/scm_run.j