fi
else
local wait="y"
- kvmx-create $GLOBAL_USER_CONFIG_FOLDER/$VM
+ kvmx_create
fi
if [ "$wait" == "y" ]; then
echo DISPLAY=:0 xrandr --output $xrandr_device --mode $name | kvmx_ssh
}
+# Wrapper to kvmx-create
+function kvmx_create {
+ if kvmx_running || kvmx_suspended; then
+ echo "$BASENAME: guest $VM is running or suspended, cannot (re-)create"
+ exit 1
+ fi
+
+ kvmx-create $KVMXFILE
+}
+
# Dispatch
if type kvmx_$ACTION 2> /dev/null | grep -q "kvmx_$ACTION ()"; then
__kvmx_initialize $*