Skip to content

Update docs how to display loaded modules#27159

Merged
tgamblin merged 5 commits intospack:developfrom
RikkiButler20:doc/spack-find-load
Nov 3, 2021
Merged

Update docs how to display loaded modules#27159
tgamblin merged 5 commits intospack:developfrom
RikkiButler20:doc/spack-find-load

Conversation

@RikkiButler20
Copy link
Copy Markdown
Contributor

@RikkiButler20 RikkiButler20 commented Nov 2, 2021

Closes #25249

Update the documentation on how to display a list of all modules loaded by spack find --loaded

@spackbot-app spackbot-app bot added the documentation Improvements or additions to documentation label Nov 2, 2021
@tldahlgren
Copy link
Copy Markdown
Contributor

I also recommend adding reminders of spack find --loaded at the end of the Using Extensions section.

You might also want to add a note at the bottom of Using 'spack load' to Manage the User Environment (workflows.rst) that the spack find --loaded command can be used to check what is actually loaded after running the shell script.

$ spack load mpich %[email protected]
$ which mpicc
~/spack/opt/linux-debian7-x86_64/[email protected]/[email protected]/bin/mpicc
$ spack find --loaded
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The use of spack find --loaded seems out of the blue here.

The content might flow better as a separate subsection (as I mentioned in my previous comment).

I also suggest, FWIW, making When you no longer... at line 889 a separate paragraph to further emphasize its purpose.

@adamjstewart
Copy link
Copy Markdown
Member

This looks great, thanks!

@RikkiButler20
Copy link
Copy Markdown
Contributor Author

@tldahlgren
For referencing spack find --loaded in Using Extensions, should I just add what the output would be if the user ran spack find --loaded?

@tldahlgren
Copy link
Copy Markdown
Contributor

tldahlgren commented Nov 2, 2021

@tldahlgren
For referencing spack find --loaded in Using Extensions, should I just add what the output would be if the user ran spack find --loaded?

It would be good to check but not necessary. It would likely be sufficient to mention the loaded packages can be checked using spack find --loaded with a link to the subsection where you introduce spack find --loaded.

@mwkrentel
Copy link
Copy Markdown
Member

You might also want to add a note at the bottom of Using 'spack load' to
Manage the User Environment (workflows.rst) that the spack find --loaded
command can be used to check what is actually loaded after running the
shell script.

Second. But if it were me, I would go farther. I would put a line in
the output of spack load -h that spack find --loaded is how you
get a list of the currently loaded modules.

As I mentioned in #25249, I looked all through spack load, unload and
module for how to do this and eventually gave up, never once thinking
that it would be in the command find.

I would go farther and make spack load --list run the same command.

IMO, this is misplaced in find. spack load and unload are how you
load and unload spack modules. So, why is list way off in another place?

@tgamblin
Copy link
Copy Markdown
Member

tgamblin commented Nov 3, 2021

Going to merge this as-is and do spack load --list in a separate PR. I actually have a version of that written up, but it'll need review, too.

@tgamblin tgamblin merged commit 1a3747b into spack:develop Nov 3, 2021
tgamblin added a commit that referenced this pull request Nov 3, 2021
See #25249 and #27159 (comment).
This adds `spack load --list` as an alias for `spack find --loaded`.  The new command is
not as powerful as `spack find --loaded`, as you can't combine it with all the queries or
formats that `spack find` provides.  However, it is more intuitively located in the command
structure in that it appears in the output of `spack load --help`.

The idea here is that people can use `spack load --list`  for simple stuff but fall back to
`spack find --loaded` if they need more.

- [x] add help to `spack load --list` that references `spack find`
- [x] factor some parts of `spack find` out to be called from `spack load`
- [x] add shell integration
- [x] add shell test
- [x] update completion
- [x] update docs
RikkiButler20 pushed a commit to RikkiButler20/spack that referenced this pull request Nov 4, 2021
See spack#25249 and spack#27159 (comment).
This adds `spack load --list` as an alias for `spack find --loaded`.  The new command is
not as powerful as `spack find --loaded`, as you can't combine it with all the queries or
formats that `spack find` provides.  However, it is more intuitively located in the command
structure in that it appears in the output of `spack load --help`.

The idea here is that people can use `spack load --list`  for simple stuff but fall back to
`spack find --loaded` if they need more.

- [x] add help to `spack load --list` that references `spack find`
- [x] factor some parts of `spack find` out to be called from `spack load`
- [x] add shell integration
- [x] add shell test
- [x] update completion
- [x] update docs
RikkiButler20 pushed a commit to RikkiButler20/spack that referenced this pull request Nov 4, 2021
See spack#25249 and spack#27159 (comment).
This adds `spack load --list` as an alias for `spack find --loaded`.  The new command is
not as powerful as `spack find --loaded`, as you can't combine it with all the queries or
formats that `spack find` provides.  However, it is more intuitively located in the command
structure in that it appears in the output of `spack load --help`.

The idea here is that people can use `spack load --list`  for simple stuff but fall back to
`spack find --loaded` if they need more.

- [x] add help to `spack load --list` that references `spack find`
- [x] factor some parts of `spack find` out to be called from `spack load`
- [x] add shell integration
- [x] add shell test
- [x] update completion
- [x] update docs
scheibelp added a commit that referenced this pull request Nov 5, 2021
See #25249 and #27159 (comment).
This adds `spack load --list` as an alias for `spack find --loaded`.  The new command is
not as powerful as `spack find --loaded`, as you can't combine it with all the queries or
formats that `spack find` provides.  However, it is more intuitively located in the command
structure in that it appears in the output of `spack load --help`.

The idea here is that people can use `spack load --list`  for simple stuff but fall back to
`spack find --loaded` if they need more.

- add help to `spack load --list` that references `spack find`
- factor some parts of `spack find` out to be called from `spack load`
- add shell tests
- update docs

Co-authored-by: Peter Josef Scheibel <[email protected]>
Co-authored-by: Richarda Butler <[email protected]>
RikkiButler20 pushed a commit to RikkiButler20/spack that referenced this pull request Nov 22, 2021
See spack#25249 and spack#27159 (comment).
This adds `spack load --list` as an alias for `spack find --loaded`.  The new command is
not as powerful as `spack find --loaded`, as you can't combine it with all the queries or
formats that `spack find` provides.  However, it is more intuitively located in the command
structure in that it appears in the output of `spack load --help`.

The idea here is that people can use `spack load --list`  for simple stuff but fall back to
`spack find --loaded` if they need more.

- [x] add help to `spack load --list` that references `spack find`
- [x] factor some parts of `spack find` out to be called from `spack load`
- [x] add shell integration
- [x] add shell test
- [x] update completion
- [x] update docs
RikkiButler20 pushed a commit to RikkiButler20/spack that referenced this pull request Nov 23, 2021
See spack#25249 and spack#27159 (comment).
This adds `spack load --list` as an alias for `spack find --loaded`.  The new command is
not as powerful as `spack find --loaded`, as you can't combine it with all the queries or
formats that `spack find` provides.  However, it is more intuitively located in the command
structure in that it appears in the output of `spack load --help`.

The idea here is that people can use `spack load --list`  for simple stuff but fall back to
`spack find --loaded` if they need more.

- [x] add help to `spack load --list` that references `spack find`
- [x] factor some parts of `spack find` out to be called from `spack load`
- [x] add shell integration
- [x] add shell test
- [x] update completion
- [x] update docs
RikkiButler20 pushed a commit to RikkiButler20/spack that referenced this pull request Dec 6, 2021
See spack#25249 and spack#27159 (comment).
This adds `spack load --list` as an alias for `spack find --loaded`.  The new command is
not as powerful as `spack find --loaded`, as you can't combine it with all the queries or
formats that `spack find` provides.  However, it is more intuitively located in the command
structure in that it appears in the output of `spack load --help`.

The idea here is that people can use `spack load --list`  for simple stuff but fall back to
`spack find --loaded` if they need more.

- [x] add help to `spack load --list` that references `spack find`
- [x] factor some parts of `spack find` out to be called from `spack load`
- [x] add shell integration
- [x] add shell test
- [x] update completion
- [x] update docs
RikkiButler20 pushed a commit to RikkiButler20/spack that referenced this pull request Dec 7, 2021
See spack#25249 and spack#27159 (comment).
This adds `spack load --list` as an alias for `spack find --loaded`.  The new command is
not as powerful as `spack find --loaded`, as you can't combine it with all the queries or
formats that `spack find` provides.  However, it is more intuitively located in the command
structure in that it appears in the output of `spack load --help`.

The idea here is that people can use `spack load --list`  for simple stuff but fall back to
`spack find --loaded` if they need more.

- [x] add help to `spack load --list` that references `spack find`
- [x] factor some parts of `spack find` out to be called from `spack load`
- [x] add shell integration
- [x] add shell test
- [x] update completion
- [x] update docs
RikkiButler20 pushed a commit to RikkiButler20/spack that referenced this pull request Jan 12, 2022
See spack#25249 and spack#27159 (comment).
This adds `spack load --list` as an alias for `spack find --loaded`.  The new command is
not as powerful as `spack find --loaded`, as you can't combine it with all the queries or
formats that `spack find` provides.  However, it is more intuitively located in the command
structure in that it appears in the output of `spack load --help`.

The idea here is that people can use `spack load --list`  for simple stuff but fall back to
`spack find --loaded` if they need more.

- [x] add help to `spack load --list` that references `spack find`
- [x] factor some parts of `spack find` out to be called from `spack load`
- [x] add shell integration
- [x] add shell test
- [x] update completion
- [x] update docs
RikkiButler20 pushed a commit to RikkiButler20/spack that referenced this pull request Jan 20, 2022
See spack#25249 and spack#27159 (comment).
This adds `spack load --list` as an alias for `spack find --loaded`.  The new command is
not as powerful as `spack find --loaded`, as you can't combine it with all the queries or
formats that `spack find` provides.  However, it is more intuitively located in the command
structure in that it appears in the output of `spack load --help`.

The idea here is that people can use `spack load --list`  for simple stuff but fall back to
`spack find --loaded` if they need more.

- [x] add help to `spack load --list` that references `spack find`
- [x] factor some parts of `spack find` out to be called from `spack load`
- [x] add shell integration
- [x] add shell test
- [x] update completion
- [x] update docs
RikkiButler20 pushed a commit to RikkiButler20/spack that referenced this pull request Jan 25, 2022
See spack#25249 and spack#27159 (comment).
This adds `spack load --list` as an alias for `spack find --loaded`.  The new command is
not as powerful as `spack find --loaded`, as you can't combine it with all the queries or
formats that `spack find` provides.  However, it is more intuitively located in the command
structure in that it appears in the output of `spack load --help`.

The idea here is that people can use `spack load --list`  for simple stuff but fall back to
`spack find --loaded` if they need more.

- [x] add help to `spack load --list` that references `spack find`
- [x] factor some parts of `spack find` out to be called from `spack load`
- [x] add shell integration
- [x] add shell test
- [x] update completion
- [x] update docs
RikkiButler20 pushed a commit to RikkiButler20/spack that referenced this pull request Jan 26, 2022
See spack#25249 and spack#27159 (comment).
This adds `spack load --list` as an alias for `spack find --loaded`.  The new command is
not as powerful as `spack find --loaded`, as you can't combine it with all the queries or
formats that `spack find` provides.  However, it is more intuitively located in the command
structure in that it appears in the output of `spack load --help`.

The idea here is that people can use `spack load --list`  for simple stuff but fall back to
`spack find --loaded` if they need more.

- [x] add help to `spack load --list` that references `spack find`
- [x] factor some parts of `spack find` out to be called from `spack load`
- [x] add shell integration
- [x] add shell test
- [x] update completion
- [x] update docs
RikkiButler20 pushed a commit to RikkiButler20/spack that referenced this pull request Feb 8, 2022
See spack#25249 and spack#27159 (comment).
This adds `spack load --list` as an alias for `spack find --loaded`.  The new command is
not as powerful as `spack find --loaded`, as you can't combine it with all the queries or
formats that `spack find` provides.  However, it is more intuitively located in the command
structure in that it appears in the output of `spack load --help`.

The idea here is that people can use `spack load --list`  for simple stuff but fall back to
`spack find --loaded` if they need more.

- [x] add help to `spack load --list` that references `spack find`
- [x] factor some parts of `spack find` out to be called from `spack load`
- [x] add shell integration
- [x] add shell test
- [x] update completion
- [x] update docs
RikkiButler20 pushed a commit to RikkiButler20/spack that referenced this pull request Mar 7, 2022
See spack#25249 and spack#27159 (comment).
This adds `spack load --list` as an alias for `spack find --loaded`.  The new command is
not as powerful as `spack find --loaded`, as you can't combine it with all the queries or
formats that `spack find` provides.  However, it is more intuitively located in the command
structure in that it appears in the output of `spack load --help`.

The idea here is that people can use `spack load --list`  for simple stuff but fall back to
`spack find --loaded` if they need more.

- [x] add help to `spack load --list` that references `spack find`
- [x] factor some parts of `spack find` out to be called from `spack load`
- [x] add shell integration
- [x] add shell test
- [x] update completion
- [x] update docs
RikkiButler20 pushed a commit to RikkiButler20/spack that referenced this pull request Mar 8, 2022
See spack#25249 and spack#27159 (comment).
This adds `spack load --list` as an alias for `spack find --loaded`.  The new command is
not as powerful as `spack find --loaded`, as you can't combine it with all the queries or
formats that `spack find` provides.  However, it is more intuitively located in the command
structure in that it appears in the output of `spack load --help`.

The idea here is that people can use `spack load --list`  for simple stuff but fall back to
`spack find --loaded` if they need more.

- [x] add help to `spack load --list` that references `spack find`
- [x] factor some parts of `spack find` out to be called from `spack load`
- [x] add shell integration
- [x] add shell test
- [x] update completion
- [x] update docs
RikkiButler20 pushed a commit to RikkiButler20/spack that referenced this pull request Mar 23, 2022
See spack#25249 and spack#27159 (comment).
This adds `spack load --list` as an alias for `spack find --loaded`.  The new command is
not as powerful as `spack find --loaded`, as you can't combine it with all the queries or
formats that `spack find` provides.  However, it is more intuitively located in the command
structure in that it appears in the output of `spack load --help`.

The idea here is that people can use `spack load --list`  for simple stuff but fall back to
`spack find --loaded` if they need more.

- [x] add help to `spack load --list` that references `spack find`
- [x] factor some parts of `spack find` out to be called from `spack load`
- [x] add shell integration
- [x] add shell test
- [x] update completion
- [x] update docs
RikkiButler20 pushed a commit to RikkiButler20/spack that referenced this pull request Mar 24, 2022
See spack#25249 and spack#27159 (comment).
This adds `spack load --list` as an alias for `spack find --loaded`.  The new command is
not as powerful as `spack find --loaded`, as you can't combine it with all the queries or
formats that `spack find` provides.  However, it is more intuitively located in the command
structure in that it appears in the output of `spack load --help`.

The idea here is that people can use `spack load --list`  for simple stuff but fall back to
`spack find --loaded` if they need more.

- [x] add help to `spack load --list` that references `spack find`
- [x] factor some parts of `spack find` out to be called from `spack load`
- [x] add shell integration
- [x] add shell test
- [x] update completion
- [x] update docs
RikkiButler20 pushed a commit to RikkiButler20/spack that referenced this pull request Apr 6, 2022
See spack#25249 and spack#27159 (comment).
This adds `spack load --list` as an alias for `spack find --loaded`.  The new command is
not as powerful as `spack find --loaded`, as you can't combine it with all the queries or
formats that `spack find` provides.  However, it is more intuitively located in the command
structure in that it appears in the output of `spack load --help`.

The idea here is that people can use `spack load --list`  for simple stuff but fall back to
`spack find --loaded` if they need more.

- [x] add help to `spack load --list` that references `spack find`
- [x] factor some parts of `spack find` out to be called from `spack load`
- [x] add shell integration
- [x] add shell test
- [x] update completion
- [x] update docs
RikkiButler20 pushed a commit to RikkiButler20/spack that referenced this pull request Apr 25, 2022
See spack#25249 and spack#27159 (comment).
This adds `spack load --list` as an alias for `spack find --loaded`.  The new command is
not as powerful as `spack find --loaded`, as you can't combine it with all the queries or
formats that `spack find` provides.  However, it is more intuitively located in the command
structure in that it appears in the output of `spack load --help`.

The idea here is that people can use `spack load --list`  for simple stuff but fall back to
`spack find --loaded` if they need more.

- [x] add help to `spack load --list` that references `spack find`
- [x] factor some parts of `spack find` out to be called from `spack load`
- [x] add shell integration
- [x] add shell test
- [x] update completion
- [x] update docs
RikkiButler20 pushed a commit to RikkiButler20/spack that referenced this pull request Jul 12, 2022
See spack#25249 and spack#27159 (comment).
This adds `spack load --list` as an alias for `spack find --loaded`.  The new command is
not as powerful as `spack find --loaded`, as you can't combine it with all the queries or
formats that `spack find` provides.  However, it is more intuitively located in the command
structure in that it appears in the output of `spack load --help`.

The idea here is that people can use `spack load --list`  for simple stuff but fall back to
`spack find --loaded` if they need more.

- [x] add help to `spack load --list` that references `spack find`
- [x] factor some parts of `spack find` out to be called from `spack load`
- [x] add shell integration
- [x] add shell test
- [x] update completion
- [x] update docs
vjranagit pushed a commit to vjranagit/spack that referenced this pull request Jan 18, 2026
See spack#25249 and spack#27159 (comment).
This adds `spack load --list` as an alias for `spack find --loaded`.  The new command is
not as powerful as `spack find --loaded`, as you can't combine it with all the queries or
formats that `spack find` provides.  However, it is more intuitively located in the command
structure in that it appears in the output of `spack load --help`.

The idea here is that people can use `spack load --list`  for simple stuff but fall back to
`spack find --loaded` if they need more.

- [x] add help to `spack load --list` that references `spack find`
- [x] factor some parts of `spack find` out to be called from `spack load`
- [x] add shell integration
- [x] add shell test
- [x] update completion
- [x] update docs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Document how to display loaded modules

6 participants