mkvm options

This commit is contained in:
phil 2024-01-15 00:02:43 +01:00
parent beca7dbdcc
commit c03c066d41

View File

@ -61,16 +61,19 @@ fi
if [[ $1 == "--help" ]] || [[ $1 == "-h" ]] || [[ $1 == "-V" ]] ; then if [[ $1 == "--help" ]] || [[ $1 == "-h" ]] || [[ $1 == "-V" ]] ; then
usage usage
fi fi
if [[ $1 == "-s" ]] ; then while [[ -n "$1" ]] ; do
startmode=1 if [[ "$1" == "-s" ]] ; then
shift startmode=1
fi shift
if [[ $1 == "-r" ]] ; then elif [[ "$1" == "-r" ]] ; then
deletemode=1 deletemode=1
shift shift
fi else
vm="$1" parm=$1
shift
fi
done
vm="${parm}"
create_vm "${vm}" create_vm "${vm}"
if [[ "${vm}" == "s-adm" ]] ; then if [[ "${vm}" == "s-adm" ]] ; then
bash addint.s-adm bash addint.s-adm
@ -130,5 +133,5 @@ else
exit 2 exit 2
fi fi
if [[ $startmode == 1 ]] ; then if [[ $startmode == 1 ]] ; then
vboxmanage startvm "${vm}"--type headless vboxmanage startvm "${vm}" --type headless
fi fi