Drop the case...esac and use if...else instead
This commit is contained in:
parent
14e18c89a1
commit
b43f59847b
11
qsgen2
11
qsgen2
@ -82,16 +82,11 @@ function _help() {
|
||||
exit
|
||||
}
|
||||
|
||||
case ${1} in
|
||||
version || -v || --version)
|
||||
if [[ "$1" == "version" || "$1" == "-v" || "$1" == "--version" ]]; then
|
||||
_version ${0:t}
|
||||
;;
|
||||
help || -h || --help)
|
||||
elif [[ "$1" == "help" || "$1" == "-h" || "$1" == "--help" ]]; then
|
||||
_help ${0:t}
|
||||
;;
|
||||
*)
|
||||
continue
|
||||
esac
|
||||
fi
|
||||
|
||||
# Loading Zsh modules
|
||||
zmodload zsh/files
|
||||
|
Loading…
Reference in New Issue
Block a user