Skip to content
This repository has been archived by the owner on Jun 26, 2024. It is now read-only.

Commit

Permalink
add script to convert image to vmdk format
Browse files Browse the repository at this point in the history
  • Loading branch information
yunshansimon committed Aug 6, 2019
1 parent b78466d commit 8b93c41
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions convert_to_vmware.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
#!/bin/bash
self_name=$0
source_img=$1
target_img=$2.vmdk

show_help_exit() {
echo "help: $self_name <source_raw_img> <target_img>"
echo "detail: convert chromiumos raw image to <target_img>.vmdk"
exit 1
}

[ -z "$source_img" ] && show_help_exit
[ ! -f "$source_img" ] && show_help_exit
[ -f ${target_img} ] && rm ${target_img}
qemu-img convert -O vmdk ${source_img} ${target_img}

0 comments on commit 8b93c41

Please sign in to comment.