#!/bin/sh

. /usr/local/lib/vmware.sh

if [ $# -ne 1 ]; then
    echo "Usage: `basename $0` <vmx>" 1>&2
    exit 1
fi

vmx="`abspath \"${1}\"`"
if [ ! -f "${vmx}" ]; then
    echo "Cannot find vmx file ${vmx}" 1>&2
    exit 1
fi

vmware-vim-cmd solo/registervm "${vmx}"
