Skip to content

Instantly share code, notes, and snippets.

@n40lab
Created May 24, 2017 09:15
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save n40lab/d64caa8545b5c67c305c485ab3096453 to your computer and use it in GitHub Desktop.
Save n40lab/d64caa8545b5c67c305c485ab3096453 to your computer and use it in GitHub Desktop.
...
vm.config.hardware.device.select { |d|
if is_disk?(d)
disks.each{|disk|
if d.backing.respond_to?(:fileName) &&
("[#{disk.elements["DATASTORE"].text}] #{disk.elements["SOURCE"].text}" == d.backing.fileName ||
disk.elements["SOURCE"].text == d.backing.fileName)
disks.delete(disk)
end
}
end
}
...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment