Hi
I am rather new with tcl, we use module to modify the env. but the module avail is getting longer, making it almost unusable so I add menus , for interactive work well , for batch it will never work .
The idea is to add a menu if after some time (5 sec) a item is not chosen then load default
the other better idea would to be able to act in bacht mode
something like
"
% module load pakcage -v 0.1
"
and version 0.1 will be loaded
my dummy script is like :
"
if { [ module-info mode display ] || [module-info mode load ] } {
puts stderr "Choose the Option to load the version you want to load"
puts stderr "1 ) Ver 0.1"
puts stderr "2 ) Ver 0.2"
puts stderr "x ) Exit"
set num [gets stdin OPTION ]
if { $OPTION == "1" } {
puts stderr "Loading ...0.1"
} elseif { $OPTION == "2" } {
puts stderr "Loading ... 0.2"
} else {
puts stderr "Exiting"
}
}
"
As I said this works interactively but not in bacth mode
Thanks
I am rather new with tcl, we use module to modify the env. but the module avail is getting longer, making it almost unusable so I add menus , for interactive work well , for batch it will never work .
The idea is to add a menu if after some time (5 sec) a item is not chosen then load default
the other better idea would to be able to act in bacht mode
something like
"
% module load pakcage -v 0.1
"
and version 0.1 will be loaded
my dummy script is like :
"
if { [ module-info mode display ] || [module-info mode load ] } {
puts stderr "Choose the Option to load the version you want to load"
puts stderr "1 ) Ver 0.1"
puts stderr "2 ) Ver 0.2"
puts stderr "x ) Exit"
set num [gets stdin OPTION ]
if { $OPTION == "1" } {
puts stderr "Loading ...0.1"
} elseif { $OPTION == "2" } {
puts stderr "Loading ... 0.2"
} else {
puts stderr "Exiting"
}
}
"
As I said this works interactively but not in bacth mode
Thanks