- Allow to declare
variant
with no list of accepted value. Such variant accepts any value specified. (fix issue #405) - Add the
redirect_output
configuration option to control on sh, bash, ksh, zsh and fish shells whether or not the output of themodule
function should be redirected from stderr to stdout. When set,redirect_output
definesMODULES_REDIRECT_OUTPUT
environment variable. - Introduce the
--redirect
/--no-redirect
command-line switches to supersede the value of theredirect_output
configuration option on sh, bash, ksh, zsh and fish shells. (fix issue #410) - Add the
--return-value
option to thegetenv
andgetvariant
modulefile commands to force to return the value of respectively designated environment variable or variant when modulefile is evaluated in display mode. (fix issue #422) - Introduce the
state
sub-command to display Modules states. - Add the
supported_shells
state to get the list of the shells that are supported bymodulecmd.tcl
through thestate
sub-command . (fix issue #426) - Filter out the variables intended for Modules private usage when processing the environment changes made by a script evaluated by
sh-to-mod
sub-command orsource-sh
modulefile command. (fix issue #427) - Doc: add
control-mode-behaviors
design notes. - Doc: add
add-new-config-option
design notes. - Set a Code of conduct for the project and its community based on the widely adopted Contributor Covenant.
- Doc: add
add-new-sub-command
design notes. - Add the
--remove-on-unload
option to theremove-path
to also remove value when modulefile is unloaded. - Raise error when an unknown option is set on
module use
ormodule unuse
modulefile command. - Rework emitted debug messages to remove obvious ones and systematically report each modulefile command processed with their arguments.
- Add the
--append-on-unload
option to theremove-path
andmodule unuse
modulefile commands to append back when modulefile is unloaded the value removed at load time or a specific value set after this option. - Add the
--prepend-on-unload
option to theremove-path
andmodule unuse
modulefile commands to prepend back when modulefile is unloaded the value removed at load time or a specific value set after this option. - Add the
--noop-on-unload
option to theunsetenv
,remove-path
andmodule unuse
modulefile commands to perform no operation when modulefile is unloaded. - Add the
--unset-on-unload
option to theunsetenv
modulefile command to also unset environment variable when modulefile is unloaded. - Add the
--set-if-undef
option to thesetenv
modulefile command to set environment variable when modulefile is loaded only this variable is not yet defined. - Install: add the
--with-bashcompletiondir
,--with-fishcompletiondir
and--with-zshcompletiondir
installation options to install shell completion scripts in their system-wide location. (fix issue #428) - Doc: add
lmod-tcl-modulefile-compat
design notes. - Introduce the
add-property
,remove-property
andextensions
modulefile commands for compatibility with Lmod Tcl modulefiles. These commands are evaluated as a no-operation command. - Introduce the
prereq-any
modulefile command for compatibility with Lmod Tcl modulefiles.prereq-any
is an alias ofprereq
command. - Produce a clear error message when wrong number of argument is received by
prereq
command. - Doc: describe
ModulesVersion
in Modules Variables section inmodulefile(4)
man page. - Set
ModuleVersion
as an alias overModulesVersion
modulefile variable for compatibility with Lmod Tcl modulefiles. - Doc: describe
reportError
andreportWarning
modulefile commands. - Add the
require-fullname
modulefile command for compatibility with Lmod Tcl modulefiles. This command aborts modulefile load evaluation if modulefile's name is not fully specified. - Add the
prereq-all
modulefile command, alias over theprereq
command which acts as an AND operation when multiple modulefiles are specified. - Add the
depends-on
modulefile command, alias over theprereq-all
command for compatibility with Lmod Tcl modulefiles. - Introduce the
keep-loaded
module tag that avoids an auto-loaded module to get automatically unloaded when its dependent modules are getting unloaded. Update defaulttag_abbrev
configuration option to add an abbreviation for the new tag (kL
) and default light and dark color palettes. - Add the
always-load
modulefile command for compatibility with Lmod Tcl modulefiles. This command loads designated modulefile and applies thekeep-loaded
tag to it. - Add the
load-any
sub-command andmodule load-any
modulefile command for compatibility with Lmod Tcl modulefiles. This command loads one modulefile from specified list. - Add support for
--not-req
option onmodule try-load
andmodule load-any
modulefile commands. - Doc: add
magic-cookie-check
design notes. - Add the
mcookie_check
configuration option that control whether the magic cookie at the start of modulefile (i.e.,#%Module
file signature) need to get checked or not. When set toeval
the number of file checks is significantly reduced when walking through modulepaths to search for modulefiles. Default value for this option is overridden by theMODULES_MCOOKIE_CHECK
environment variable. - Doc: describe
puts
Tcl command and its specific feature when used in modulefile. - Create the
prestdout
channel forputs
modulefile command to be able to send content that will be evaluated in current shell session prior any other content. (fix issue #432) - Add the
family
modulefile command for compatibility with Lmod Tcl modulefiles. This command defines family name as a module alias over currently loading module and express a conflict over this name to ensure only one member of a family can be loaded in user environment.family
also defines theMODULES_FAMILY_<NAME>
andLMOD_FAMILY_<NAME>
environment variables. - Doc: add
reduce-io-load
cookbook recipe. - Add the ability to filter the list of loaded modules returned by
list
sub-command. Filtering pattern could be part of module name, symbolic version or alias and is matched in a case insensitive manner by default. It could also leverage theAdvanced module version specifiers
syntax. - Add support for
--starts-with
and--contains
options onlist
sub-command. - Doc: add
shell-completion
design notes. - Introduce
complete
anduncomplete
modulefile commands to respectively enable and disable shell completion for a given command name. bash, tcsh and fish shells are supported. - Track shell completion changes of bash, tcsh and fish shell scripts on
sh-to-mod
sub-command andsource-sh
modulefile command. - Fix typos found in code, tests and documentation. (contribution from Dimitri Papadopoulos Orfanos)
- Update the
sh-to-mod
andsource-sh
mechanisms to support nested function definition on fish shell. - Fix the
sh-to-mod
andsource-sh
mechanisms to correctly detect functions with a_
character in their name on fish shell. - Update the
module
shell function definition for sh-kind shell to enclose the output generated bymodulecmd.tcl
in quotes in order to pass it to the eval command. This change fixes definition of shell function, especially when coming from shell script evaluation over thesh-to-mod
andsource-sh
mechanisms. (fix issue #434) - Fix csh shell alias detection on
sh-to-mod
andsource-sh
mechanisms when enclosed in parenthesis. (fix issue #434) - Include for fish shell environment analysis on
sh-to-mod
andsource-sh
mechanisms the private functions defined by evaluated script, in order to catch all definitions that may be useful for shell completion. - Fix the
sh-to-mod
andsource-sh
mechanisms to correctly detect empty function on fish shell. - Script: add
pre-commit
git hook script to help verify if commits are free of misspellings (with codespell tool) and trailing spaces. - Doc: fix typos found in documentation with Aspell utility.
- Doc: describe
Dependencies between modulefiles
inmodulefile(4)
man page. (fix issues #431 and #433) - Script: update
pre-commit
git hook script to spell check documentation files with Aspell tool. - Script: add
commit-msg
git hook script to spell check commit message with Aspell tool. - Doc: clarify that
#%Module
is a file signature also called Modules magic cookie. - Doc: update the
module ENVIRONMENT
section inmodule(1)
man page to provide for each Modules environment variable the name of the configuration option that could be used to set the variable with theconfig
sub-command. - Doc: clarify in
module(1)
man page thatMODULES_SET_SHELL_STARTUP
,MODULES_SHELLS_WITH_KSH_FPATH
andMODULES_WA_277
should be set prior Modules initialization to get taken into account. - Doc: update
INSTALL
document to provide the name of the configuration option linked the installation options. - Doc: describe in
module(1)
man page the default value of each configuration option and linked installation option and command-line switches. - Doc: add Configuration options section in
INSTALL
document with a table summarizing all configuration options and their relative installation options and environment variables. - Add the
pushenv
modulefile command for compatibility with Lmod Tcl modulefiles. This command sets designated environment variable with specified value and save the previous value set to restore it when the modulefile is unloaded. Previous values are saved in a__MODULES_PUSHENV_<VAR>
environment variable. - Doc: add
Compatibility with Lmod Tcl modulefile
section inmodulefile(4)
man page. - Update definition of the
module()
python function and python initialization script to explicitly send output tosys.stderr
to get the ability to catch this content. - Lib: handle
sysconf
error in function implementing theinitStateUsergroups
procedure. (contribution from Lukáš Zaoral) - Introduce the
--tag
option for theload
,try-load
,load-any
,switch
sub-commands and associatedmodule
modulefile commands andprereq
,prereq-all
,depends-on
andalways-load
modulefile commands. This new option applies specified tags to the module to load. - Record tags set to loaded modules with the
--tag
option in the__MODULES_LMEXTRATAG
environment variable to make this information persists after module being loaded. - When saving a collection, record loaded module tags set with the
--tag
option and those resulting from module load states (likeauto-loaded
andkeep-loaded
). The--notuasked
string previously used to designate auto-loaded modules in collection is changed into the--tag=auto-loaded
option. - Introduce the
collection_pin_tag
configuration option, that records in collection all tags set on loaded modules when enabled. Option is disabled by default and when set it defines theMODULES_COLLECTION_PIN_TAG
environment variable. - When a collection is saved, its content starts with a
#%Module5.1
file signature if--tag
option is recorded in it. - Update the
restore
,savelist
,saveshow
andis-saved
sub-commands to exclude from result or return an error when checking a collection expressing a higher Modules version requirement in its header signature than the one currently in use. - Doc: describe differences between run-command file and modulefile interpretation in
modulefile(4)
man page. - Doc: describe
module
sub-commands available as modulefile Tcl command for each interpretation context inmodulefile(4)
man page. - When loading a module with some extra tags defined through the
--tag
option, if this module is already loaded the new tags are added to those already set. - When reporting result of
avail
orlist
sub-commands, enclose module names in single quotes if they contain a space character. - When mentioning the loading, unloading or refreshing evaluation of a module, report the tags associated to this module as done when printing results of
list
sub-command. - Fix
log-module-command
cookbook recipe not to break Modules initialization when using providedsiteconfig.tcl
file. (fix issue #453 with contribution from Eric Burgueño) - Mention tagging evaluation of a module, when tag list of an already loaded module is updated.