-
Notifications
You must be signed in to change notification settings - Fork 129
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
issue #382: Support a hook so that sites can add decoration to spider…
… level 1 output
- Loading branch information
Robert McLay
committed
May 10, 2019
1 parent
d6605db
commit 4e32f54
Showing
14 changed files
with
152 additions
and
36 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
Lmod 8.1+ | ||
(8.1.1) * Issue #392: include family info in spiderT and all other products based on spiderT like | ||
dbT and the software page. | ||
|
||
(8.1.2) * Issue #382: Adding a spider_decoration hook so that sites can modify the output of spider | ||
level 1 output. |
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,16 +2,19 @@ | |
step 1 | ||
lua ProjectDIR/src/lmod.in.lua bash --regression_testing --version | ||
=========================== | ||
Modules based on Lua: Version 8.1 2019-05-07 15:35 -05:00 | ||
Modules based on Lua: Version 8.1.1 2019-05-10 11:12 -05:00 | ||
by Robert McLay [email protected] | ||
=========================== | ||
step 2 | ||
lua ProjectDIR/src/lmod.in.lua bash --regression_testing avail | ||
=========================== | ||
ProjectDIR/rt/softwarePage/mf | ||
foo/1.0 foo/1.1 (D) foo/1.3 | ||
foo/1.0 (g) foo/1.1 (m,D) foo/1.3 (T) | ||
Where: | ||
D: Default Module | ||
T: Testing | ||
g: built for GPU | ||
m: built for host and native MIC | ||
Use "module spider" to find all possible modules. | ||
Use "module keyword key1 key2 ..." to search for all possible modules matching any of the "keys". | ||
=========================== | ||
|
@@ -26,3 +29,17 @@ runSpiderCmd -o dbT ProjectDIR/rt/softwarePage/mf | |
step 5 | ||
runSpiderCmd -o softwarePageLua ProjectDIR/rt/softwarePage/mf | ||
=========================== | ||
=========================== | ||
step 6 | ||
lua ProjectDIR/src/lmod.in.lua bash --regression_testing spider foo | ||
=========================== | ||
foo: | ||
Description: | ||
This is a descript | ||
Versions: | ||
foo/1.0 | ||
foo/1.1 | ||
foo/1.3 | ||
For detailed information about a specific "foo" module (including how to load the modules) use the module's full name. | ||
For example: | ||
$ module spider foo/1.3 |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
help([[foo v.2.0]]) | ||
whatis("Description: foo description") | ||
whatis("Version: 1.0") | ||
whatis("Categories: foo") | ||
whatis("Category: foo") | ||
family("bar") |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
help([[foo v1.0]]) | ||
whatis("Description: foo description") | ||
whatis("Version: 1.0") | ||
whatis("Categories: foo") | ||
whatis("Category: foo") | ||
family("bar") | ||
add_property("arch","gpu") |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
help([[foo v1.1]]) | ||
whatis("Description: foo description") | ||
whatis("Version: 1.1") | ||
whatis("Categories: foo") | ||
whatis("Category: foo") | ||
family("bar") | ||
add_property("arch","mic") |
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,7 @@ | |
step 1 | ||
lua ProjectDIR/src/lmod.in.lua bash --regression_testing --version | ||
=========================== | ||
Modules based on Lua: Version 7.7.14 2017-11-16 16:23 -07:00 | ||
Modules based on Lua: Version 8.1.1 2019-05-10 11:12 -05:00 | ||
by Robert McLay [email protected] | ||
=========================== | ||
step 2 | ||
|
@@ -39,3 +39,16 @@ where "Foo" is the name of a module. | |
To find detailed information about a particular package you | ||
must specify the version if there is more than one version: | ||
$ module spider Foo/11.1 | ||
=========================== | ||
step 7 | ||
lua ProjectDIR/src/lmod.in.lua bash --regression_testing spider python | ||
=========================== | ||
python: | ||
Description: | ||
Python with scientific packages | ||
Versions: | ||
python/2.7.3 (Application) | ||
python/3.3.0 (Application) | ||
For detailed information about a specific "python" module (including how to load the modules) use the module's full name. | ||
For example: | ||
$ module spider python/3.3.0 |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,6 +3,8 @@ | |
-- author: [email protected] | ||
|
||
require("lmod_system_execute") | ||
require("string_utils") | ||
|
||
local Dbg = require("Dbg") | ||
local dbg = Dbg:dbg() | ||
local hook = require("Hook") | ||
|
@@ -173,6 +175,13 @@ function loadPkgDefaults() | |
return pkg | ||
end | ||
|
||
function spdrDecoration(v) | ||
local cat = (v.Category or ""):trim() | ||
return cat | ||
end | ||
|
||
hook.register("spider_decoration", spdrDecoration) | ||
|
||
sandbox_registration { | ||
getAppRoot = getAppRoot | ||
, loadPkgDefaults = loadPkgDefaults | ||
|
This file contains 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
This file contains 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
This file contains 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
This file contains 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