Commit 538b97bc authored by gsell's avatar gsell

Merge branch 'master' of gitorious.psi.ch:pmodules/src

parents 2d928c5e 031c6dd5
......@@ -32,6 +32,8 @@ module() {
[[ ${#args[@]} == 0 ]] && args+=( 'help' )
[[ ${#args[@]} == 1 ]] && args+=( '--' )
# we have to eval here, otherwise we cannot do something like
# $ module load gcc/5.2.0 openmpi/1.8.8 hdf5/1.8.15
local -i i=1
for (( i=1; i < ${#args[@]}; i++ )); do
eval $( "${modulecmd}" bash "${args[0]}" "${switches[@]}" "${args[i]}" )
......
......@@ -1485,12 +1485,19 @@ subcommand_search() {
#
subcommand_help() {
local opts=''
opts=$(pmodules::get_options -- '' "$@") || usage
opts=$(pmodules::get_options -o HV\? -l version -l help -- "$@") || usage
eval set -- "${opts}"
local arg=''
while (( $# > 0 )); do
case $1 in
-[hH] | -\? | --help )
usage
;;
-V | --version )
print_version
std::die 1
;;
-- )
:
;;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment