Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

not sure which modules are "default" #9

Open
edoyango opened this issue Feb 22, 2023 · 3 comments
Open

not sure which modules are "default" #9

edoyango opened this issue Feb 22, 2023 · 3 comments
Labels
enhancement New feature or request

Comments

@edoyango
Copy link

> module_avail('python')
 [1] "python/2.7.18"      "python/3.10.4"      "python/3.5.1"      
 [4] "python/3.5.3"       "python/3.6.5-intel" "python/3.7.0"      
 [7] "python/3.7.13"      "python/3.8.3"       "python/3.8.8"      
[10] "python/3.9.5" 

module_avail() doesn't show which one's the default Python. For example, in bash, the default module is underlined.

image

@multimeric
Copy link
Member

This is a casualty of the fact that I now output character vectors in R instead of just forwarding the module avail output to the terminal. I'm not certain how important this information is though, as I would discourage loading the default version in general. I could maybe add a new filter that only shows default versions, or a detailed command that outputs more verbose information (but only if the --json flag is supported). Other suggestions welcome.

@multimeric multimeric added the enhancement New feature or request label Feb 22, 2023
@edoyango
Copy link
Author

Since you're already walking the directory tree, you could parse the .version file located in each folder (if it exists). e.g. for python

$ cat /stornext/System/data/modulefiles/bioinf/its/python/.version
#%Module1.0###########################################################
###
### version file for module
###

set ModulesVersion 3.8.8

@multimeric
Copy link
Member

Interesting, I didn't know about that. I might add a filter to select only those default versions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants