modules.py: adding 'include' logic to TCL module generation.#2902
Closed
TheQueasle wants to merge 1 commit intospack:developfrom
Closed
modules.py: adding 'include' logic to TCL module generation.#2902TheQueasle wants to merge 1 commit intospack:developfrom
TheQueasle wants to merge 1 commit intospack:developfrom
Conversation
…arbitrary TCL code to be included in the module files
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
Feb 19, 2017
refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
Feb 19, 2017
refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies
16 tasks
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
Feb 22, 2017
refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
Feb 23, 2017
refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
Mar 2, 2017
refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
Mar 16, 2017
refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
Apr 3, 2017
refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
Apr 7, 2017
refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
Apr 7, 2017
refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
Apr 17, 2017
refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
Apr 25, 2017
refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
Apr 26, 2017
* modulefiles: are now generated using a template engine refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies * template dirs in config.yaml + override mechanism for pkgs Modifications: - added the entry 'template_dirs' to config.yaml - added an override mechanism for templates ('modules.yaml' beats 'package.py' beats 'default') - added unit tests * modules: improved test layout and readability Modifications: - factored common fixtures in conftest.py - extracted configurations from tests and put them into yaml files - fixed 'verbose' keyword in modules.yaml and corresponding tests * simplified template engine file layout Modifications: - added a 'context_property' decorator - simplified file layout for tengine (python module instead of package) - added tests for tengine.Context * contexts can be extended from packages and modules.yaml * short description it's the first paragraph of docstrings * module refresh: changed behavior when no module type is specified Modifications: - spack module refresh without `--module-type` specified tries to regenerate all known module types - spack module rm without `--module-type` specified tries to delete all known module types - added tests for the new behavior * module file: added configure options to module files if applicable * lmod: added tests on exceptional paths of execution * python3: fixed issues with python2 vs python3 compatibility * jinja2: added external package * tcl: fixed bugs with naming_scheme and autoload. Added regression tests. * markupsafe: added external package * module tutorial: updated docs, fixed a few bugs caught in the meanwhile. * reference docs for modules: reorganized section The idea is to have only three topics at the highest level: - shell support + spack load/unload use/unuse - module file generation (a.k.a. APIs + modules.yaml) - module file maintenance (spack module refresh/rm) Module file generation will cover the entries in modules.yaml
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
Apr 26, 2017
refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
Apr 28, 2017
refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
May 1, 2017
refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
May 3, 2017
* modulefiles: are now generated using a template engine refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies * template dirs in config.yaml + override mechanism for pkgs Modifications: - added the entry 'template_dirs' to config.yaml - added an override mechanism for templates ('modules.yaml' beats 'package.py' beats 'default') - added unit tests * modules: improved test layout and readability Modifications: - factored common fixtures in conftest.py - extracted configurations from tests and put them into yaml files - fixed 'verbose' keyword in modules.yaml and corresponding tests * simplified template engine file layout Modifications: - added a 'context_property' decorator - simplified file layout for tengine (python module instead of package) - added tests for tengine.Context * contexts can be extended from packages and modules.yaml * short description it's the first paragraph of docstrings * module refresh: changed behavior when no module type is specified Modifications: - spack module refresh without `--module-type` specified tries to regenerate all known module types - spack module rm without `--module-type` specified tries to delete all known module types - added tests for the new behavior * module file: added configure options to module files if applicable * lmod: added tests on exceptional paths of execution * python3: fixed issues with python2 vs python3 compatibility * jinja2: added external package * tcl: fixed bugs with naming_scheme and autoload. Added regression tests. * markupsafe: added external package * module tutorial: updated docs, fixed a few bugs caught in the meanwhile. * reference docs for modules: reorganized section The idea is to have only three topics at the highest level: - shell support + spack load/unload use/unuse - module file generation (a.k.a. APIs + modules.yaml) - module file maintenance (spack module refresh/rm) Module file generation will cover the entries in modules.yaml
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
May 5, 2017
* modulefiles: are now generated using a template engine refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies * template dirs in config.yaml + override mechanism for pkgs Modifications: - added the entry 'template_dirs' to config.yaml - added an override mechanism for templates ('modules.yaml' beats 'package.py' beats 'default') - added unit tests * modules: improved test layout and readability Modifications: - factored common fixtures in conftest.py - extracted configurations from tests and put them into yaml files - fixed 'verbose' keyword in modules.yaml and corresponding tests * simplified template engine file layout Modifications: - added a 'context_property' decorator - simplified file layout for tengine (python module instead of package) - added tests for tengine.Context * contexts can be extended from packages and modules.yaml * short description it's the first paragraph of docstrings * module refresh: changed behavior when no module type is specified Modifications: - spack module refresh without `--module-type` specified tries to regenerate all known module types - spack module rm without `--module-type` specified tries to delete all known module types - added tests for the new behavior * module file: added configure options to module files if applicable * lmod: added tests on exceptional paths of execution * python3: fixed issues with python2 vs python3 compatibility * jinja2: added external package * tcl: fixed bugs with naming_scheme and autoload. Added regression tests. * markupsafe: added external package * module tutorial: updated docs, fixed a few bugs caught in the meanwhile. * reference docs for modules: reorganized section The idea is to have only three topics at the highest level: - shell support + spack load/unload use/unuse - module file generation (a.k.a. APIs + modules.yaml) - module file maintenance (spack module refresh/rm) Module file generation will cover the entries in modules.yaml
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
May 7, 2017
* modulefiles: are now generated using a template engine refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies * template dirs in config.yaml + override mechanism for pkgs Modifications: - added the entry 'template_dirs' to config.yaml - added an override mechanism for templates ('modules.yaml' beats 'package.py' beats 'default') - added unit tests * modules: improved test layout and readability Modifications: - factored common fixtures in conftest.py - extracted configurations from tests and put them into yaml files - fixed 'verbose' keyword in modules.yaml and corresponding tests * simplified template engine file layout Modifications: - added a 'context_property' decorator - simplified file layout for tengine (python module instead of package) - added tests for tengine.Context * contexts can be extended from packages and modules.yaml * short description it's the first paragraph of docstrings * module refresh: changed behavior when no module type is specified Modifications: - spack module refresh without `--module-type` specified tries to regenerate all known module types - spack module rm without `--module-type` specified tries to delete all known module types - added tests for the new behavior * module file: added configure options to module files if applicable * lmod: added tests on exceptional paths of execution * python3: fixed issues with python2 vs python3 compatibility * jinja2: added external package * tcl: fixed bugs with naming_scheme and autoload. Added regression tests. * markupsafe: added external package * module tutorial: updated docs, fixed a few bugs caught in the meanwhile. * reference docs for modules: reorganized section The idea is to have only three topics at the highest level: - shell support + spack load/unload use/unuse - module file generation (a.k.a. APIs + modules.yaml) - module file maintenance (spack module refresh/rm) Module file generation will cover the entries in modules.yaml
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
May 9, 2017
* modulefiles: are now generated using a template engine refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies * template dirs in config.yaml + override mechanism for pkgs Modifications: - added the entry 'template_dirs' to config.yaml - added an override mechanism for templates ('modules.yaml' beats 'package.py' beats 'default') - added unit tests * modules: improved test layout and readability Modifications: - factored common fixtures in conftest.py - extracted configurations from tests and put them into yaml files - fixed 'verbose' keyword in modules.yaml and corresponding tests * simplified template engine file layout Modifications: - added a 'context_property' decorator - simplified file layout for tengine (python module instead of package) - added tests for tengine.Context * contexts can be extended from packages and modules.yaml * short description it's the first paragraph of docstrings * module refresh: changed behavior when no module type is specified Modifications: - spack module refresh without `--module-type` specified tries to regenerate all known module types - spack module rm without `--module-type` specified tries to delete all known module types - added tests for the new behavior * module file: added configure options to module files if applicable * lmod: added tests on exceptional paths of execution * python3: fixed issues with python2 vs python3 compatibility * jinja2: added external package * tcl: fixed bugs with naming_scheme and autoload. Added regression tests. * markupsafe: added external package * module tutorial: updated docs, fixed a few bugs caught in the meanwhile. * reference docs for modules: reorganized section The idea is to have only three topics at the highest level: - shell support + spack load/unload use/unuse - module file generation (a.k.a. APIs + modules.yaml) - module file maintenance (spack module refresh/rm) Module file generation will cover the entries in modules.yaml
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
May 10, 2017
refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
May 10, 2017
* modulefiles: are now generated using a template engine refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies * template dirs in config.yaml + override mechanism for pkgs Modifications: - added the entry 'template_dirs' to config.yaml - added an override mechanism for templates ('modules.yaml' beats 'package.py' beats 'default') - added unit tests * modules: improved test layout and readability Modifications: - factored common fixtures in conftest.py - extracted configurations from tests and put them into yaml files - fixed 'verbose' keyword in modules.yaml and corresponding tests * simplified template engine file layout Modifications: - added a 'context_property' decorator - simplified file layout for tengine (python module instead of package) - added tests for tengine.Context * contexts can be extended from packages and modules.yaml * short description it's the first paragraph of docstrings * module refresh: changed behavior when no module type is specified Modifications: - spack module refresh without `--module-type` specified tries to regenerate all known module types - spack module rm without `--module-type` specified tries to delete all known module types - added tests for the new behavior * module file: added configure options to module files if applicable * lmod: added tests on exceptional paths of execution * python3: fixed issues with python2 vs python3 compatibility * jinja2: added external package * tcl: fixed bugs with naming_scheme and autoload. Added regression tests. * markupsafe: added external package * module tutorial: updated docs, fixed a few bugs caught in the meanwhile. * reference docs for modules: reorganized section The idea is to have only three topics at the highest level: - shell support + spack load/unload use/unuse - module file generation (a.k.a. APIs + modules.yaml) - module file maintenance (spack module refresh/rm) Module file generation will cover the entries in modules.yaml
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
May 15, 2017
refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
May 16, 2017
refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
Jun 6, 2017
refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
Jun 18, 2017
refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
Jun 30, 2017
refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
Jul 15, 2017
refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
Jul 31, 2017
refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
Aug 9, 2017
refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
Aug 17, 2017
refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
Aug 21, 2017
refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
Sep 7, 2017
refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
Sep 11, 2017
refers spack#2902 refers spack#3173 Modifications in detail: - hooked `jinja2` into spack (but still need to fix the facade) - refactored `modules.py` into the package `spack/modules` - refactored `test/modules.py` accordingly to the item above - added templates for the three kind of module files we generate - extended lmod to multi-providers and deeper hierarchies
alalazo
added a commit
to epfl-scitas/spack
that referenced
this pull request
Sep 12, 2017
spack#3173 jinja2 has been hooked into Spack. The python module `modules.py` has been splitted into several modules under the python package `spack/modules`. Unit tests stressing module file generation have been refactored accordingly. The module file generator for Lmod has been extended to multi-providers and deeper hierarchies.
becker33
pushed a commit
that referenced
this pull request
Sep 19, 2017
* Module files now are generated using a template engine refers #2902 #3173 jinja2 has been hooked into Spack. The python module `modules.py` has been splitted into several modules under the python package `spack/modules`. Unit tests stressing module file generation have been refactored accordingly. The module file generator for Lmod has been extended to multi-providers and deeper hierarchies. * Improved the support for templates in module files. Added an entry in `config.yaml` (`template_dirs`) to list all the directories where Spack could find templates for `jinja2`. Module file generators have a simple override mechanism to override template selection ('modules.yaml' beats 'package.py' beats 'default'). * Added jinja2 and MarkupSafe to vendored packages. * Spec.concretize() sets mutual spec-package references The correct place to set the mutual references between spec and package objects at the end of concretization. After a call to concretize we should now be ensured that spec is the same object as spec.package.spec. Code in `build_environment.py` that was performing the same operation has been turned into an assertion to be defensive on the new behavior. * Improved code and data layout for modules and related tests. Common fixtures related to module file generation have been extracted in `conftest.py`. All the mock configurations for module files have been extracted from python code and have been put into their own yaml file. Added a `context_property` decorator for the template engine, to make it easy to define dictionaries out of properties. The default for `verbose` in `modules.yaml` is now False instead of True. * Extendable module file contexts + short description from docstring The contexts that are used in conjunction with `jinja2` templates to generate module files can now be extended from package.py and modules.yaml. Module files generators now infer the short description from package.py docstring (and as you may expect it's the first paragraph) * 'module refresh' regenerates all modules by default `module refresh` without `--module-type` specified tries to regenerate all known module types. The same holds true for `module rm` Configure options used at build time are extracted and written into the module files where possible. * Fixed python3 compatibility, tests for Lmod and Tcl. Added test for exceptional paths of execution when generating Lmod module files. Fixed a few compatibility issues with python3. Fixed a bug in Tcl with naming_scheme and autoload + unit tests * Updated module file tutorial docs. Fixed a few typos in docstrings. The reference section for module files has been reorganized. The idea is to have only three topics at the highest level: - shell support + spack load/unload use/unuse - module file generation (a.k.a. APIs + modules.yaml) - module file maintenance (spack module refresh/rm) Module file generation will cover the entries in modules.yaml Also: - Licenses have been updated to include NOTICE and extended to 2017 - docstrings have been reformatted according to Google style * Removed redundant arguments to RPackage and WafPackage. All the callbacks in `RPackage` and `WafPackage` that are not build phases have been modified not to accept a `spec` and a `prefix` argument. This permits to leverage the common `configure_args` signature to insert by default the configuration arguments into the generated module files. I think it's preferable to handling those packages differently than `AutotoolsPackage`. Besides only one package seems to override one of these methods. * Fixed broken indentation + improved resiliency of refresh Fixed broken indentation in `spack module refresh` (probably a rebase gone silently wrong?). Filter the writers for blacklisted specs before searching for name clashes. An error with a single writer will not stop regeneration, but instead will print a warning and continue the command.
Member
|
I'll close this one as now you can extend module files with custom templates. Right now, you can find brief examples in the unit tests, e.g. here. In the incoming days I'll start writing more docs for that and other parts of Spack. If you have questions or remarks feel free to ping me. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Enable arbitrary TCL code to be included in the module files via the
modules.yamlconfig file.For example, I want to include
/shared/modulefiles/include/logging.tclon every TCL modulefile generated via spack.modules.yaml:Module file generated after fake installing
htop:Currently, the logic only checks if the file to include exists, and fails if it does not.
I chose the word
includefor use inmodules.yamlbecause that is what I thought the TCL command was called when I started this feature...but after testing I discovered it issource. I'm not sure if I likeincludeorsourcebetter for the config yaml...I brought up this feature request during SC16 at one of the Spack talks (which were all awesome btw) and no one seemed too opposed to it. So I finally decided to sit down and attempt to add the feature.
I'm pretty new to Python development, so I'm sorry for any glaring issues you see with this PR 😑