Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions INSTALL.rst
Original file line number Diff line number Diff line change
Expand Up @@ -672,6 +672,26 @@ instance :instopt:`--disable-set-manpath<--enable-set-manpath>`):

.. versionadded:: 4.3

.. instopt:: --enable-like-lmod

Enable all options that make the :command:`module` command behave similarly
to Lmod, the alternative :command:`module` implementation developed in Lua.
This option is equivalent to the cumulative use of
:instopt:`--with-abort-on-error=load:ml:reload:switch<--with-abort-on-error>`,
:instopt:`--enable-conflict-unload`, :instopt:`--enable-path-entry-reorder`,
:instopt:`--enable-require-via`,
:instopt:`--with-search-match=contains<--with-search-match>`,
:instopt:`--with-sticky-purge=warning<--with-sticky-purge>` and
:instopt:`--enable-unique-name-loaded`. (default=no)

An installation option set after :instopt:`--enable-like-lmod` on the
:command:`configure` command line supersedes the value defined by this
option.

.. only:: html or latex

.. versionadded:: 5.8

.. instopt:: --enable-mcookie-version-check

Enable check of the version specified right after Modules magic cookie
Expand Down
6 changes: 6 additions & 0 deletions NEWS.rst
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,12 @@ Modules 5.8.0 (not yet released)
option is changed with the :subcmd:`config` sub-command from an
initialization rc file or a sourced modulefile. (fix issue #740 with
contribution from Achim Gsell)
* Install: add installation option :instopt:`--enable-like-lmod` that enables
all the options making the :command:`module` command behave similarly to
Lmod: *abort on error* on :subcmd:`load` and :subcmd:`switch` sub-commands,
*conflict unload* and *require via* mechanisms, one module loaded per module
name, path entry reordering, *contains* search match and sticky modules kept
with a warning on :subcmd:`purge`.


.. _5.7 release notes:
Expand Down
19 changes: 19 additions & 0 deletions configure
Original file line number Diff line number Diff line change
Expand Up @@ -296,6 +296,8 @@ Optional Features:
--enable-libtclenvmodules
build and install the Modules Tcl extension library
and enable its load in modulecmd.tcl [yes]
--enable-like-lmod enable all options that make module command behave
similarly to Lmod [no]
--enable-mcookie-version-check
enable check of the version specified right after
Modules magic cookie in modulefiles, which defines
Expand Down Expand Up @@ -937,6 +939,23 @@ for arg in "$@"; do
# shellcheck disable=SC2034
requirevia=y ;
fi ;;
--enable-like-lmod*|--disable-like-lmod)
val=$(get_feature_value "$arg") ;
if [ "$val" = 'y' ]; then
abortonerror='load:ml:reload:switch' ;
# shellcheck disable=SC2034
conflictunload=y ;
# shellcheck disable=SC2034
pathentryreorder=y ;
# shellcheck disable=SC2034
requirevia=y ;
# shellcheck disable=SC2034
searchmatch=contains ;
# shellcheck disable=SC2034
stickypurge=warning ;
# shellcheck disable=SC2034
uniquenameloaded=y ;
fi ;;
--with-dark-background-colors=*|--without-dark-background-colors)
darkbgcolors=$(get_package_value "$arg" "") ;;
--with-light-background-colors=*|--without-light-background-colors)
Expand Down
5 changes: 5 additions & 0 deletions doc/source/other-implementations.rst
Original file line number Diff line number Diff line change
Expand Up @@ -225,6 +225,11 @@ implementation.
* - ``myModuleVersion()``
- :mfcmd:`module-info moduleversion<module-info>`

Several Modules features that correspond to Lmod behaviors are not enabled by
default. The :instopt:`--enable-like-lmod` installation option enables all of
them at once to get a :command:`module` command that behaves similarly to
Lmod.

.. _Irreversible module actions: https://lmod.readthedocs.io/en/latest/370_irreversible.html
.. _NAG file: https://lmod.readthedocs.io/en/latest/140_deprecating_modules.html
.. _Custom labels for avail: https://lmod.readthedocs.io/en/latest/200_avail_custom.html
Expand Down
Loading