Hello All,
sh-to-mod sub-command and source-sh modulefile command are mechanisms to
translate the environment changes of a shell script into a modulefile.
After the recent support of shell completion definition, several fixes have
been made on these mechanisms:
* Support nested function definition on fish shell.
* 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 by modulecmd.tcl in quotes in order to pass it to the
eval command. This change fixes definition of shell function
* Fix csh shell alias detection when enclosed in parenthesis.
* Include for fish shell environment analysis the private functions defined
by evaluated script, in order to catch all definitions that may be useful
for shell completion.
* Correctly detect empty function on fish shell.
With all these improvements, shell function are better handled when
evaluating complex shell scripts.
Tests have been added to track any regression of these mechanisms against
well known setup env scripts (Spack, Miniconda, OpenFOAM)
All of these improvements will be available in upcoming version 5.1.
Regards,
Xavier
|