Invert get.sh name check, don't use -v and -q together.

This commit is contained in:
j3s 2020-05-16 16:06:39 -05:00
parent 109e57ffc9
commit 60a8f34a9b

View File

@ -7,7 +7,7 @@ if echo "$vmname" | grep -vqE '^(cvm|capsul)-[a-z0-9]{10}$'; then
exit 1 exit 1
fi fi
if virsh list --name --all | grep -vqE "^$vmname$" ; then if ! virsh list --name --all | grep -qE "^$vmname$" ; then
echo "Error: $vmname not found" echo "Error: $vmname not found"
exit 1 exit 1
fi fi