Fixed destroyjails so it can destroy multiple jails. Minor formatting cleanup around usage code.
This commit is contained in:
parent
77f1589701
commit
3193319d2c
@ -46,13 +46,13 @@ while getopts ":i:r:u:d:g:h" opt
|
|||||||
;;
|
;;
|
||||||
u ) updatejails=("$OPTARG")
|
u ) updatejails=("$OPTARG")
|
||||||
until [[ $(eval "echo \${$OPTIND}") =~ ^-.* ]] || [ -z $(eval "echo \${$OPTIND}") ]; do
|
until [[ $(eval "echo \${$OPTIND}") =~ ^-.* ]] || [ -z $(eval "echo \${$OPTIND}") ]; do
|
||||||
updateljails+=($(eval "echo \${$OPTIND}"))
|
updatejails+=($(eval "echo \${$OPTIND}"))
|
||||||
OPTIND=$((OPTIND + 1))
|
OPTIND=$((OPTIND + 1))
|
||||||
done
|
done
|
||||||
;;
|
;;
|
||||||
d ) destroyjails=("$OPTARG")
|
d ) destroyjails=("$OPTARG")
|
||||||
until [[ $(eval "echo \${$OPTIND}") =~ ^-.* ]] || [ -z $(eval "echo \${$OPTIND}") ]; do
|
until [[ $(eval "echo \${$OPTIND}") =~ ^-.* ]] || [ -z $(eval "echo \${$OPTIND}") ]; do
|
||||||
deletejails+=($(eval "echo \${$OPTIND}"))
|
destroyjails+=($(eval "echo \${$OPTIND}"))
|
||||||
OPTIND=$((OPTIND + 1))
|
OPTIND=$((OPTIND + 1))
|
||||||
done
|
done
|
||||||
;;
|
;;
|
||||||
|
Loading…
Reference in New Issue
Block a user