.. _customizing-cime: =============================== CIME user config directory =============================== CIME recognizes a user-created custom configuration directory, ``$HOME/.cime``. The contents of this directory may include any of the following files: * ``config`` This file must have a format which follows the python config format. See `Python Config Parser Examples `_ In the [main] block you can set the following variables: * ``CIME_MODEL=[e3sm, cesm]`` * ``PROJECT=`` Used to specify a project id for compute accounting and directory permissions when on a batch system. * ``CHARGE_ACCOUNT=`` Used to override the accounting (only) aspect of PROJECT * ``MAIL_USER=`` Used to request a non-default email for batch summary output * ``MAIL_TYPE=[never,all,begin,fail,end]`` Any **or** all the above valid values can be set to list the batch events that emails will be sent for. * **create_test** input arguments Any argument to the **create_test** script can have its default changed by listing it here with the new default. * The following is an example ``config`` file: :: [main] CIME_MODEL=cesm SRCROOT=$CIMEROOT/.. MAIL_TYPE=end [create_test] MAIL_TYPE=fail * ``config_machines.xml`` This file must the same format as **$CIMEROOT/config/$model/machines/config_machines.xml** with the appropriate definitions for your machine. If you have a customized version of this file in the directory ``$HOME/.cime``, it will **append** to the file in ``$CIMEROOT/config/$model/machines/config_machines.xml``. For an example of a **config_machines.xml** file for a linux cluster, look at **$CIMEROOT/config/xml_schemas/config_machines_template.xml**. * ``cmake_macros`` This subdirectory contains a hierarchy of cmake macros files which are used to generate the flags to be used in the compilation of a case. The cmake macro files are examined in the following order, with later files takeing precidence over earlier ones. * universal.cmake * *COMPILER*.cmake * *OS*.cmake * *MACHINE*.cmake * *COMPILER*_*OS*.cmake * *COMPILER*_*MACHINE*.cmake * ``config_compilers.xml`` **DEPRECATED use cmake_macros** This file permits you to customize compiler settings for your machine and is appended to the file **$CIMEROOT/config/$model/machines/config_compilers.xml**. The following is an example of what would be needed for customized a ibm compiler flags on a BlueGeneQ machine. :: -g -qfullpath -qmaxmem=-1 -qspillsize=2500 -qextname=flush -O3 -qstrict -qinline=auto -qsmp=omp -qsmp=omp:noopt -DLINUX --build=powerpc-bgp-linux --host=powerpc64-suse-linux -Wl,--relax -Wl,--allow-multiple-definition * ``config_batch.xml`` This file permits you to customize batch settings for you machine and is appended to the file **$CIMEROOT/config/$model/machines/config_batch.xml**. The following is an example of what would be needed to add batch settings for pbs on the machine brutus. :: -S {{ shell }} batch