-
Notifications
You must be signed in to change notification settings - Fork 207
CUG 6.5 BASICS What are CIME xml variables and CIME environment variables
Like in CESM1.0 and CESM1.1, CESM1.2 cases are customized, built and run largely through setting what CESM calls "environment variables". These actually appear to the user as variables defined in xml files. Those files appear in the case directory once a case is created and are named something like env_*.xml. They are converted to actual environment variables via a csh script called ccsm_getenv. That script calls a perl script called xml2env that converts the xml files to shell files that are then sourced and removed. The ccsm_getenv and xml2env exist in the $CASEROOT/Tools directory. The environment variables are specified in xml files to support extra automated error checking and automatic generation of env variable documentation. If you want to have the cesm environment variables in your local shell environment, do the following
> cd $CASEROOT
> source ./Tools/ccsm_getenv
CESM recommends using the xmlchange tool to modify env variables. This will decrease the chance that typographical errors will creep into the xml files. Conversion of the xml files to environment variables can fail silently with certain xml format errors. To use xmlchange, do, for instance,
> cd $CASEROOT
> ./xmlchange STOP_OPTION=nmonths
> ./xmlchange STOP_N=6