urn:noticeable:projects:cbzeG7wTvAIqj21zbUmxEnvironment Modules Updatescea-hpc.github.io/modules2019-09-21T17:15:17.413ZCopyright © Environment ModulesNoticeablehttps://storage.noticeable.io/projects/cbzeG7wTvAIqj21zbUmx/newspages/UPOFxJbXsysxyt1L7iHB/01h55ta3gsp13j52cdnky8js2v-header-logo.pnghttps://storage.noticeable.io/projects/cbzeG7wTvAIqj21zbUmx/newspages/UPOFxJbXsysxyt1L7iHB/01h55ta3gsp13j52cdnky8js2v-header-logo.png#b70e0burn:noticeable:publications:BdriPsWhEsmTN5tpUhf52019-09-21T14:45:00.001Z2019-09-21T17:15:17.413ZModules 4.3.1 releasedModules version 4.3.1 is out. This new release provides fixes for the issues found recently on the 4.3 serie. The changes introduced in this bugfix release are: Contrib: add mb script to bench Modules versions. Correct modulecmd.tcl...<p>Modules version 4.3.1 is out. This new release provides fixes for the issues found recently on the 4.3 serie.</p> <p>The changes introduced in this bugfix release are:</p> <ul> <li>Contrib: add <code>mb</code> script to bench Modules versions.</li> <li>Correct <code>modulecmd.tcl</code> script startup to correctly report error in case Tcl extension library fails to load. (fix issue #284)</li> <li>Install: fix typo on <code>CFLAGS</code> definition in <code>lib/Makefile</code>. (fix issue #287 with contribution from Felix Neumärker)</li> <li>Remove useless code in Modules Tcl extension library</li> <li>Make URLs in README correctly rendered in HTML. (contribution from Per Persson)</li> <li>Doc: clarify modulefile evaluation modes in modulefile.4 man page. (fix issue #289)</li> <li>When looking at the closest match among loaded modules when switching module with just a single module argument specified, load the information on the currently set environment to get the alternative names of loaded modules prior to look at closest module match. (fix issue #290)</li> <li>Doc: describe the way to determine the site-specific configuration script location in cookbook recipes implying the installation of such a file. (fix issue #266)</li> <li>Doc: add <em>Log module command</em> recipe to cookbook. (fix issue #283)</li> <li>Doc: add <em>Expose procedures and variables to modulefiles</em> recipe to cookbook.</li> <li>Doc: add <em>Make defined modulepaths persist over sudo</em> recipe to cookbook.</li> <li>Doc: add <em>Ensure user fully qualify the modules they use</em> recipe to cookbook.</li> <li>Introduce the <code>wa_277</code> configuration option to workaround an issue with Tcsh history mechanism. Default <code>module</code> alias definition for Tcsh hits an issue with shell history mechanism: erroneous history entries are recorded each time the <code>module</code> command is called. When <code>wa_277</code> option is enabled (which sets the <code>MODULES_WA_277</code> environment variable to <em>1</em>), an alternative module alias is defined which fixes the history mechanism issue. However the alternative definition of the module alias weakens shell evaluation of the code produced by modulefiles. Characters with special meaning for Tcsh shell (like <em>{</em> and <em>}</em>) may not be used anymore in shell alias definition elsewhere the evaluation of the code produced by modulefiles will return a syntax error. (fix issue #277)</li> <li>Doc: add <em>Tips for Code Reuse in Modulefiles</em> recipe to cookbook. (contribution from Tom Payerle)</li> <li>Fix the <code>whatis</code> and <code>paths</code> sub-command results for module symbolic versions targeting a directory when <code>implicit_default</code> configuration option is disabled. No error is returned and same result is now obtained whether the symbolic name or its target is used as argument for those two sub-commands. (fix issue #294)</li> <li>Fix the <code>whatis</code> and <code>paths</code> sub-command results for module aliases targeting a directory when <code>implicit_default</code> configuration option is disabled. No error is returned and same result is now obtained whether the alias name or its target is used as argument for those two sub-commands. (fix issue #295)</li> <li>Rework all the ternary operator expressions in <code>modulecmd.tcl</code> that may result in a <em>nan</em> value (whatever the case used to write this string) as the <code>expr</code> Tcl command raises an error when it returns such a value, which breaks Modules as soon as a modulefile, an alias or a symbolic version is named <em>nan</em>. (fix issue #296)</li> </ul> <p>The list of all changes made in this new version are described in the NEWS document. Details on the new features introduced in the 4.2 series are provided in the MIGRATING document.</p> <p><a href="http://modules.readthedocs.io/en/stable/NEWS.html?utm_source=noticeable&amp;utm_campaign=cbzeg7wtvaiqj21zbumx.modules-4-3-1-released&amp;utm_content=publication+link&amp;utm_id=cbzeG7wTvAIqj21zbUmx.UPOFxJbXsysxyt1L7iHB.BdriPsWhEsmTN5tpUhf5&amp;utm_medium=newspage" target="_blank" rel="noopener">http://modules.readthedocs.io/en/stable/NEWS.html</a><br> <a href="http://modules.readthedocs.io/en/stable/MIGRATING.html?utm_source=noticeable&amp;utm_campaign=cbzeg7wtvaiqj21zbumx.modules-4-3-1-released&amp;utm_content=publication+link&amp;utm_id=cbzeG7wTvAIqj21zbUmx.UPOFxJbXsysxyt1L7iHB.BdriPsWhEsmTN5tpUhf5&amp;utm_medium=newspage" target="_blank" rel="noopener">http://modules.readthedocs.io/en/stable/MIGRATING.html</a></p> <p>The tarball of this new version can be downloaded at:</p> <p><a href="http://downloads.sourceforge.net/modules/modules-4.3.1.tar.gz?utm_source=noticeable&amp;utm_campaign=cbzeg7wtvaiqj21zbumx.modules-4-3-1-released&amp;utm_content=publication+link&amp;utm_id=cbzeG7wTvAIqj21zbUmx.UPOFxJbXsysxyt1L7iHB.BdriPsWhEsmTN5tpUhf5&amp;utm_medium=newspage" target="_blank" rel="noopener">http://downloads.sourceforge.net/modules/modules-4.3.1.tar.gz</a></p> <p>If you encounter any issue, please let us know by creating a ticket on the project bug tracker at:</p> <p><a href="https://github.com/cea-hpc/modules/issues?utm_source=noticeable&amp;utm_campaign=cbzeg7wtvaiqj21zbumx.modules-4-3-1-released&amp;utm_content=publication+link&amp;utm_id=cbzeG7wTvAIqj21zbUmx.UPOFxJbXsysxyt1L7iHB.BdriPsWhEsmTN5tpUhf5&amp;utm_medium=newspage" target="_blank" rel="noopener">https://github.com/cea-hpc/modules/issues</a></p> <p>I would like to thank Felix Neumärker, Per Persson, Tom Payerle, @benwanlin, @zzxtty, @cdorbell2 and @wenzler for their code contribution or bug report that helped to build this release.</p> Xavier Delaruelle[email protected]urn:noticeable:publications:0W93dqVMDMyEVm7jdMRW2019-07-26T19:44:00.001Z2019-07-26T19:49:03.666ZModules 4.3.0 releasedModules version 4.3.0 is out. This new version adds bunch of new features to tailor module to your needs. It is backward-compatible with previous version 4 releases and primarily adds features and fixes bugs. Major new features...<p>Modules version 4.3.0 is out. This new version adds bunch of new features to tailor <code>module</code> to your needs. It is backward-compatible with previous version 4 releases and primarily adds features and fixes bugs. Major new features introduced in v4.3.0 since v4.2 are:</p> <ul> <li><a href="https://timeline.noticeable.io/cbzeG7wTvAIqj21zbUmx/posts/modulepath-rc-file?utm_source=noticeable&amp;utm_campaign=cbzeg7wtvaiqj21zbumx.modules-4-3-0-released&amp;utm_content=publication+link&amp;utm_id=cbzeG7wTvAIqj21zbUmx.UPOFxJbXsysxyt1L7iHB.0W93dqVMDMyEVm7jdMRW&amp;utm_medium=newspage" target="_blank" rel="noopener">Modulepath rc file</a></li> <li><a href="https://timeline.noticeable.io/cbzeG7wTvAIqj21zbUmx/posts/further-i-o-operations-optimization?utm_source=noticeable&amp;utm_campaign=cbzeg7wtvaiqj21zbumx.modules-4-3-0-released&amp;utm_content=publication+link&amp;utm_id=cbzeG7wTvAIqj21zbUmx.UPOFxJbXsysxyt1L7iHB.0W93dqVMDMyEVm7jdMRW&amp;utm_medium=newspage" target="_blank" rel="noopener">Further I/O operations optimization</a></li> <li><a href="https://timeline.noticeable.io/cbzeG7wTvAIqj21zbUmx/posts/colored-output?utm_source=noticeable&amp;utm_campaign=cbzeg7wtvaiqj21zbumx.modules-4-3-0-released&amp;utm_content=publication+link&amp;utm_id=cbzeG7wTvAIqj21zbUmx.UPOFxJbXsysxyt1L7iHB.0W93dqVMDMyEVm7jdMRW&amp;utm_medium=newspage" target="_blank" rel="noopener">Colored output</a></li> <li><a href="https://timeline.noticeable.io/cbzeG7wTvAIqj21zbUmx/posts/configure-modulecmd-with-config-sub-command?utm_source=noticeable&amp;utm_campaign=cbzeg7wtvaiqj21zbumx.modules-4-3-0-released&amp;utm_content=publication+link&amp;utm_id=cbzeG7wTvAIqj21zbUmx.UPOFxJbXsysxyt1L7iHB.0W93dqVMDMyEVm7jdMRW&amp;utm_medium=newspage" target="_blank" rel="noopener">Configure modulecmd with config sub-command</a></li> <li><a href="https://timeline.noticeable.io/cbzeG7wTvAIqj21zbUmx/posts/control-module-command-verbosity?utm_source=noticeable&amp;utm_campaign=cbzeg7wtvaiqj21zbumx.modules-4-3-0-released&amp;utm_content=publication+link&amp;utm_id=cbzeG7wTvAIqj21zbUmx.UPOFxJbXsysxyt1L7iHB.0W93dqVMDMyEVm7jdMRW&amp;utm_medium=newspage" target="_blank" rel="noopener">Control module command verbosity</a></li> <li><a href="https://timeline.noticeable.io/cbzeG7wTvAIqj21zbUmx/posts/non-recursive-module-avail-search?utm_source=noticeable&amp;utm_campaign=cbzeg7wtvaiqj21zbumx.modules-4-3-0-released&amp;utm_content=publication+link&amp;utm_id=cbzeG7wTvAIqj21zbUmx.UPOFxJbXsysxyt1L7iHB.0W93dqVMDMyEVm7jdMRW&amp;utm_medium=newspage" target="_blank" rel="noopener">Non-recursive module avail search</a></li> <li><a href="https://timeline.noticeable.io/cbzeG7wTvAIqj21zbUmx/posts/disabling-implicit-default-version?utm_source=noticeable&amp;utm_campaign=cbzeg7wtvaiqj21zbumx.modules-4-3-0-released&amp;utm_content=publication+link&amp;utm_id=cbzeG7wTvAIqj21zbUmx.UPOFxJbXsysxyt1L7iHB.0W93dqVMDMyEVm7jdMRW&amp;utm_medium=newspage" target="_blank" rel="noopener">Disabling implicit default version</a></li> <li><a href="https://timeline.noticeable.io/cbzeG7wTvAIqj21zbUmx/posts/search-matching-style?utm_source=noticeable&amp;utm_campaign=cbzeg7wtvaiqj21zbumx.modules-4-3-0-released&amp;utm_content=publication+link&amp;utm_id=cbzeG7wTvAIqj21zbUmx.UPOFxJbXsysxyt1L7iHB.0W93dqVMDMyEVm7jdMRW&amp;utm_medium=newspage" target="_blank" rel="noopener">Search matching style</a></li> </ul> <p>Details on these features and all the others included in this new release are provided in the MIGRATING document. The list of all changes made in this new version are described in the NEWS document.</p> <p><a href="http://modules.readthedocs.io/en/stable/MIGRATING.html?utm_source=noticeable&amp;utm_campaign=cbzeg7wtvaiqj21zbumx.modules-4-3-0-released&amp;utm_content=publication+link&amp;utm_id=cbzeG7wTvAIqj21zbUmx.UPOFxJbXsysxyt1L7iHB.0W93dqVMDMyEVm7jdMRW&amp;utm_medium=newspage" target="_blank" rel="noopener">http://modules.readthedocs.io/en/stable/MIGRATING.html</a><br> <a href="http://modules.readthedocs.io/en/stable/NEWS.html?utm_source=noticeable&amp;utm_campaign=cbzeg7wtvaiqj21zbumx.modules-4-3-0-released&amp;utm_content=publication+link&amp;utm_id=cbzeG7wTvAIqj21zbUmx.UPOFxJbXsysxyt1L7iHB.0W93dqVMDMyEVm7jdMRW&amp;utm_medium=newspage" target="_blank" rel="noopener">http://modules.readthedocs.io/en/stable/NEWS.html</a></p> <p>The tarball of this new version can be downloaded at:</p> <p><a href="http://downloads.sourceforge.net/modules/modules-4.3.0.tar.gz?utm_source=noticeable&amp;utm_campaign=cbzeg7wtvaiqj21zbumx.modules-4-3-0-released&amp;utm_content=publication+link&amp;utm_id=cbzeG7wTvAIqj21zbUmx.UPOFxJbXsysxyt1L7iHB.0W93dqVMDMyEVm7jdMRW&amp;utm_medium=newspage" target="_blank" rel="noopener">http://downloads.sourceforge.net/modules/modules-4.3.0.tar.gz</a></p> <p>If you encounter any issue, please let us know by creating a ticket on the project bug tracker at:</p> <p><a href="https://github.com/cea-hpc/modules/issues?utm_source=noticeable&amp;utm_campaign=cbzeg7wtvaiqj21zbumx.modules-4-3-0-released&amp;utm_content=publication+link&amp;utm_id=cbzeG7wTvAIqj21zbUmx.UPOFxJbXsysxyt1L7iHB.0W93dqVMDMyEVm7jdMRW&amp;utm_medium=newspage" target="_blank" rel="noopener">https://github.com/cea-hpc/modules/issues</a></p> <p>Special thanks to Felix Neumärker, Ben Bowers, Jacques Raphanel and Colin Marquardt for their code contributions on this release.</p> Xavier Delaruelle[email protected]urn:noticeable:publications:V7Zw17tbEDxmAWorMio22019-07-25T19:29:00.001Z2019-07-25T19:31:10.729ZControl module command verbosityThe ability to control message verbosity has been added so module command can be configured whether it should display more or less information. Available verbosity levels from the least to the most verbose are: silent: turn off error...<p>The ability to control message verbosity has been added so <code>module</code> command can be configured whether it should display more or less information. Available verbosity levels from the least to the most verbose are:</p> <ul> <li><code>silent</code>: turn off error, warning and informational messages but does not affect module command output result.</li> <li><code>concise</code>: enable error and warning messages but disable informational messages.</li> <li><code>normal</code>: turn on informational messages, like a report of the additional module evaluations triggered by loading or unloading modules, aborted evaluation issues or a report of each module evaluation occurring during a <code>restore</code> or <code>source</code> sub-commands.</li> <li><code>verbose</code>: add additional informational messages, like a systematic report of the loading or unloading module evaluations.</li> <li><code>debug</code>: print debugging messages about module command execution.</li> </ul> <p>Default verbosity level can be controlled at configure time with the <code>--with-verbosity</code> option, which could be passed any of the above level names. This default verbosity level could be superseded with the <code>MODULES_VERBOSITY</code> environment variable, which could be set through the <code>config</code> sub-command with the <code>verbosity</code> option. Command-line switches <code>--silent</code>, <code>--verbose</code> and <code>--debug</code> supersede in turns any other verbosity configuration to respectively set module command silent, verbose or in debug mode.</p> <p>This new feature will be included into the imminent v4.3 release.</p> Xavier Delaruelle[email protected]urn:noticeable:publications:xw1hM5EwOk2co88sSzVS2019-07-25T06:59:00.001Z2019-07-25T07:01:28.221ZStoring initialization config files in etcdirWhen initializing the module command in a shell session, initialization configuration files stored in the defined configuration directory are taken into account if present instead of the configuration files stored in the initialization...<p>When initializing the <code>module</code> command in a shell session, initialization configuration files stored in the defined configuration directory are taken into account if present instead of the configuration files stored in the initialization script directory. When they are stored in the configuration directory, these configuration files are named <code>initrc</code> and <code>modulespath</code> instead of respectively <code>modulerc</code> and <code>.modulespath</code>.</p> <p>This change gives the ability for package manager to move these configuration files from the /usr directory to /etc.</p> <p>The location of the installation of those files can be controlled with configure option <code>--with-initconf-in</code>, which accepts <code>etcdir</code> and <code>initdir</code> values.</p> <p>This new feature is available in git repository and will be included into the upcoming v4.3 release.</p> Xavier Delaruelle[email protected]urn:noticeable:publications:o9NHsGsuiBwOuITwmDG62019-07-24T16:43:00.001Z2019-07-24T16:44:54.081ZDisabling shell startup file configurationThe MODULESSETSHELLSTARTUP environment variable is introduced to control whether or not shell startup file should be set to ensure module command is defined once shell has been initialized. When enabled, the ENV and BASHENV environment...<p>The <code>MODULES_SET_SHELL_STARTUP</code> environment variable is introduced to control whether or not shell startup file should be set to ensure <code>module</code> command is defined once shell has been initialized. When enabled, the <code>ENV</code> and <code>BASH_ENV</code> environment variables are set, when <code>module</code> function is defined, to the Modules bourne shell initialization script.</p> <p>Starting version 4.0 this ability was enabled so this new configuration option offers a mean to disable it in case it is not desired.</p> <p>Configure options <code>--enable-set-shell-startup</code> and <code>--disable-set-shell-startup</code> define this setting which can be superseded by the environment variable. This environment variable can be set with the <code>config</code> module sub-command via the <code>set_shell_startup</code> option.</p> <p>This new feature is available in git repository and will be included into the upcoming v4.3 release.</p> Xavier Delaruelle[email protected]urn:noticeable:publications:6QBaAJxtrIPoEjs1iUWN2019-07-24T08:18:00.001Z2019-07-24T08:19:20.976ZSearch matching styleThe MODULESSEARCHMATCH environment variable is introduced to define the matching style to perform when searching for available modules. With starts_with value, modules whose name begins by search query string are returned. When search...<p>The <code>MODULES_SEARCH_MATCH</code> environment variable is introduced to define the matching style to perform when searching for available modules. With <code>starts_with</code> value, modules whose name begins by search query string are returned. When search match style is set to <code>contains</code>, modules returned are those whose fully qualified name contains search query string.</p> <p>Configure option <code>--with-search-match</code> defines this setting which can be superseded by the environment variable. This environment variable can be set with the <code>config</code> module sub-command via the <code>search_match</code> option. All these configuration means can be superseded in turns by the <code>--starts-with</code>/<code>-S</code> and <code>--contains</code>/<code>-C</code> command-line switches of the <code>avail</code> module sub-command.</p> <pre><code>$ module avail oo $ module avail -C oo ----------- /path/to/modulefiles ------------ foo/1 foo/2 $ module config search_match contains $ module avail oo ----------- /path/to/modulefiles ------------ foo/1 foo/2 </code></pre> <p>This new feature is available in git repository and will be included into the upcoming v4.3 release.</p> Xavier Delaruelle[email protected]urn:noticeable:publications:kpRwLlJdmPCWbxt7jNta2019-07-23T08:13:00.001Z2019-07-23T08:15:35.109ZDisabling implicit default versionThe MODULESIMPLICITDEFAULT environment variable is introduced to choose whether an implicit default version should be defined for modules with no default version explicitly defined. When enabled, which is the default behavior, a module...<p>The <code>MODULES_IMPLICIT_DEFAULT</code> environment variable is introduced to choose whether an implicit default version should be defined for modules with no default version explicitly defined. When enabled, which is the default behavior, a module version is automatically selected (latest one) when the generic name of the module is passed. When implicit default is disabled and no default version is explicitly defined for a module, the name of this module to evaluate should be fully qualified elsewhere an error is returned.</p> <p>Configure option <code>--enable-implicit-default</code> defines this setting which can be superseded by the environment variable. This environment variable can be set with the <code>config</code> module sub-command via the <code>implicit_default</code>. The superseding mechanism can also be disabled with configure option <code>--with-locked-configs=implicit_default</code>, in case you do not want users to play with this setting.</p> <pre><code>$ module config implicit_default 0 $ module load foo ERROR: No default version defined for 'foo' $ module config implicit_default 1 $ module load -v foo Loading foo/2 </code></pre> <p>This new feature is available in git repository and will be included into the upcoming v4.3 release.</p> Xavier Delaruelle[email protected]urn:noticeable:publications:7AL6fQDQNvXQroaLm4cU2019-07-22T20:28:00.001Z2019-07-22T20:33:45.193ZMODULES_UNLOAD_MATCH_ORDERThe MODULESUNLOADMATCH_ORDER environment variable is introduced to set whether the firstly or the lastly loaded module should be selected for unload when multiple loaded modules match unload request. Configure option --with-unload-match...<p>The <code>MODULES_UNLOAD_MATCH_ORDER</code> environment variable is introduced to set whether the firstly or the lastly loaded module should be selected for unload when multiple loaded modules match unload request.</p> <p>Configure option <code>--with-unload-match-order</code> defines this setting which can be superseded by the environment variable. By default, lastly loaded module is selected and it is recommended to keep this behavior when used modulefiles express dependencies between each other.</p> <p>This new feature is available in git repository and will be included into the upcoming v4.3 release.</p> Xavier Delaruelle[email protected]urn:noticeable:publications:nq1jW4lsPlFr75GoGVMT2019-07-15T14:28:00.001Z2019-07-15T15:19:03.562ZConfigure modulecmd with config sub-commandThe config sub-command has been added to module to help getting or setting the modulecmd.tcl options. With no additional command-line argument, this sub-command reports the current value of all existing options with a mention to indicate...<p>The <strong>config</strong> sub-command has been added to <code>module</code> to help getting or setting the <strong>modulecmd.tcl</strong> options. With no additional command-line argument, this sub-command reports the current value of all existing options with a mention to indicate if this value has been overridden from a command-line switch or from an environment variable.</p> <p>See the description of this sub-command in the <a href="https://modules.readthedocs.io/en/latest/module.html?utm_source=noticeable&amp;utm_campaign=cbzeg7wtvaiqj21zbumx.configure-modulecmd-with-config-sub-command&amp;utm_content=publication+link&amp;utm_id=cbzeG7wTvAIqj21zbUmx.UPOFxJbXsysxyt1L7iHB.nq1jW4lsPlFr75GoGVMT&amp;utm_medium=newspage" target="_blank" rel="noopener">module man page</a> for a complete reference on existing configuration options.</p> <p>Most of the options can be altered by passing the option name and a value to the sub-command. Setting an option by this mean overrides its default value, set at installation time in <strong>modulecmd.tcl</strong> script, by defining the environment variable which supersedes this default.:</p> <pre><code>$ module config auto_handling 1 $ module config auto_handling Modules Release 4.3.0 (2019-XX-XX) - Config. name ----.- Value (set by if default overridden) ---------- auto_handling 1 (env-var) </code></pre> <p>When command-line switch <code>--reset</code> and an option name is passed to the <strong>config</strong> sub-command, it restores default value for configuration option by unsetting related environment variable.</p> <p>With command-line switch <code>--dump-state</code>, the <strong>config</strong> sub-command reports, in addition to currently set options, the current state of <strong>modulecmd.tcl</strong> script and Modules-related environment variables. Providing the output of the <code>module config --dump-state</code> command when submitting an issue to the Modules project will help to analyze the situation.</p> <p>This change is available in git repository and will be included into the next feature release v4.3.</p> Xavier Delaruelle[email protected]urn:noticeable:publications:kQdmsuMcxBcHaOGixGGj2019-06-24T12:16:00.001Z2019-07-01T06:03:27.350ZColored outputThe ability to graphically enhance some part of the produced output has been added to improve readability. Among others, error, warning and info message prefixes can be colored as well as modulepath, module alias and symbolic version...<p>The ability to graphically enhance some part of the produced output has been added to improve readability. Among others, error, warning and info message prefixes can be colored as well as modulepath, module alias and symbolic version.</p> <p><img src="https://storage.noticeable.io/projects/cbzeG7wTvAIqj21zbUmx/publications/kQdmsuMcxBcHaOGixGGj/01h55ta3gsg7nwffszn6e97fa8-image.png" alt="Example on the module avail sub-command"></p> <p>Color mode can be set to <code>never</code>, <code>auto</code> or <code>always</code>. When color mode is set to <code>auto</code>, output is colored only if the standard error output channel is attached to a terminal.</p> <p>Default color mode could be controlled at configure time with the <code>--enable-color</code> and the <code>--disable-color</code> option, which respectively correspond to the <code>auto</code> and <code>never</code> color mode. This default mode could be superseded with the <code>MODULES_COLOR</code> environment variable and the <code>--color</code> command-line switch.</p> <p>Color to apply to each element can be controlled with the <code>MODULES_COLORS</code> environment variable or the <code>--with-dark-background-colors</code> and <code>--with-light-background-colors</code> configure options. These variable and options take as value a colon-separated list in the same fashion <code>LS_COLORS</code> does. In this list, output item that should be highlighted is designated by a key which is associated to a <a href="https://en.wikipedia.org/wiki/ANSI_escape_code?utm_source=noticeable&amp;utm_campaign=cbzeg7wtvaiqj21zbumx.colored-output&amp;utm_content=publication+link&amp;utm_id=cbzeG7wTvAIqj21zbUmx.UPOFxJbXsysxyt1L7iHB.kQdmsuMcxBcHaOGixGGj&amp;utm_medium=newspage#SGR_(Select_Graphic_Rendition)_parameters" target="_blank" rel="noopener">Select Graphic Rendition (SGR) code</a>.</p> <p>The <code>MODULES_TERM_BACKGROUND</code> environment variable and the <code>--with-terminal-background</code> configure option help Modules to determine if the color set for dark background or the color set for light background should be used to color output in case no specific color set is defined with the <code>MODULES_COLORS</code> variable.</p> <p>Output items able to be colorized and their relative key are: highlighted element (<code>hi</code>), debug information (<code>db</code>), tag separator (<code>se</code>); Error (<code>er</code>), warning (<code>wa</code>), module error (<code>me</code>) and info (<code>in</code>) message prefixes; Modulepath (<code>mp</code>), directory (<code>di</code>), module alias (<code>al</code>), module symbolic version (<code>sy</code>), module <code>default</code> version (<code>de</code>) and modulefile command (<code>cm</code>).</p> <p>For instance the default color set for a terminal with dark background is defined to <code>hi=1:db=2:se=2:er=91:wa=93:me=95:in=94:mp=1;94:di=94:al=96:sy=95:de=4:cm=92</code></p> <p><img src="https://storage.noticeable.io/projects/cbzeG7wTvAIqj21zbUmx/publications/kQdmsuMcxBcHaOGixGGj/01h55ta3gskva5ck22s9vvaztd-image.png" alt="Example output when an error obtained"></p> <p>When colored output is enabled and a specific graphical rendition is defined for module <em>default</em> version, the <code>default</code> symbol is omitted and instead the defined graphical rendition is applied to the relative modulefile. When colored output is enabled and a specific graphical rendition is defined for module alias, the <code>@</code> symbol is omitted.</p> <p><img src="https://storage.noticeable.io/projects/cbzeG7wTvAIqj21zbUmx/publications/kQdmsuMcxBcHaOGixGGj/01h55ta3gs30sv0xzvpzsv1r00-image.png" alt="Example output of a module load triggering additional loads"></p> <p><a href="https://sourceforge.net/p/modules/mailman/message/36701420/?utm_source=noticeable&amp;utm_campaign=cbzeg7wtvaiqj21zbumx.colored-output&amp;utm_content=publication+link&amp;utm_id=cbzeG7wTvAIqj21zbUmx.UPOFxJbXsysxyt1L7iHB.kQdmsuMcxBcHaOGixGGj&amp;utm_medium=newspage" target="_blank" rel="noopener">Read discussion thread on mailing-list</a></p> Xavier Delaruelle[email protected]