tar cf "$imgfile" "$outfile"
-if [ "$(echo "nativedisk; source '(ahci0)/$outfile';" | "${grubshell}" --qemu-opts="-drive id=disk,file=$imgfile,if=none -device ahci,id=ahci -device ide-hd,drive=disk,bus=ahci.0 " | tail -n 1)" != "Hello World" ]; then
+v=$(echo "nativedisk; source '(ahci0)/$outfile';" |
+ "${grubshell}" --qemu-opts="-drive id=disk,file=$imgfile,if=none
+ -device ahci,id=ahci
+ -device ide-hd,drive=disk,bus=ahci.0" |
+ tail -n 1)
+if [ "$v" != "Hello World" ]; then
rm "$imgfile"
rm "$outfile"
exit 1
exit 0;;
esac
-if [ "$(echo hello | "${grubshell}" --boot=cd)" != "Hello World" ]; then
+v=$(echo hello | "${grubshell}" --boot=cd)
+if [ "$v" != "Hello World" ]; then
exit 1
fi
esac
-if [ "$(echo hello | "${grubshell}" --grub-mkimage-extra=--compress=xz)" != "Hello World" ]; then
+v=$(echo hello | "${grubshell}" --grub-mkimage-extra=--compress=xz)
+if [ "$v" != "Hello World" ]; then
exit 1
fi
-if [ "$(echo hello | "${grubshell}" --grub-mkimage-extra=--compress=none)" != "Hello World" ]; then
+v=$(echo hello | "${grubshell}" --grub-mkimage-extra=--compress=none)
+if [ "$v" != "Hello World" ]; then
exit 1
fi
tar cf "$imgfile" "$outfile"
-if [ "$(echo "nativedisk; source '(usb0)/$outfile';" | "${grubshell}" --qemu-opts="-device ich9-usb-ehci1 -drive id=my_usb_disk,file=$imgfile,if=none -device usb-storage,drive=my_usb_disk" | tail -n 1)" != "Hello World" ]; then
+v=$(echo "nativedisk; source '(usb0)/$outfile';" |
+ "${grubshell}" --qemu-opts="-device ich9-usb-ehci1
+ -drive id=my_usb_disk,file=$imgfile,if=none
+ -device usb-storage,drive=my_usb_disk" |
+ tail -n 1)
+if [ "$v" != "Hello World" ]; then
rm "$imgfile"
rm "$outfile"
exit 1
exit 0;;
esac
-if [ "$(echo hello | "${grubshell}" --boot=fd --mkrescue-arg="--compress=xz --fonts= --locales= --themes= -no-pad")" != "Hello World" ]; then
+v=$(echo hello | "${grubshell}" --boot=fd --mkrescue-arg="--compress=xz --fonts= --locales= --themes= -no-pad")
+if [ "$v" != "Hello World" ]; then
exit 1
fi
exit 77
fi
-if [ "$(echo hello | "${grubshell}" --mkrescue-arg=--compress=gz)" != "Hello World" ]; then
+v=$(echo hello | "${grubshell}" --mkrescue-arg=--compress=gz)
+if [ "$v" != "Hello World" ]; then
exit 1
fi
exit 0;;
esac
-if [ "$(echo hello | "${grubshell}" --boot=hd)" != "Hello World" ]; then
+v=$(echo hello | "${grubshell}" --boot=hd)
+if [ "$v" != "Hello World" ]; then
exit 1
fi
exit 77
fi
-if [ "$(echo hello | "${grubshell}" --mkrescue-arg=--compress=lzo)" != "Hello World" ]; then
+v=$(echo hello | "${grubshell}" --mkrescue-arg=--compress=lzo)
+if [ "$v" != "Hello World" ]; then
exit 1
fi
exit 0;;
esac
-if [ "$(echo hello | "${grubshell}" --boot=net)" != "Hello World" ]; then
+v=$(echo hello | "${grubshell}" --boot=net)
+if [ "$v" != "Hello World" ]; then
exit 1
fi
tar cf "$imgfile" "$outfile"
-if [ "$(echo "nativedisk; source '(usb0)/$outfile';" | "${grubshell}" --qemu-opts="-device pci-ohci -drive id=my_usb_disk,file=$imgfile,if=none -device usb-storage,drive=my_usb_disk" | tail -n 1)" != "Hello World" ]; then
+v=$(echo "nativedisk; source '(usb0)/$outfile';" |
+ "${grubshell}" --qemu-opts="-device pci-ohci
+ -drive id=my_usb_disk,file=$imgfile,if=none
+ -device usb-storage,drive=my_usb_disk" |
+ tail -n 1)
+if [ "$v" != "Hello World" ]; then
rm "$imgfile"
rm "$outfile"
exit 1
tar cf "$imgfile" "$outfile"
-if [ "$(echo "nativedisk; source '($indisk)/$outfile';" | "${grubshell}" --qemu-opts="-$disk $imgfile")" != "Hello World" ]; then
+v=$(echo "nativedisk; source '($indisk)/$outfile';" | "${grubshell}" --qemu-opts="-$disk $imgfile")
+if [ "$v" != "Hello World" ]; then
rm "$imgfile"
rm "$outfile"
exit 1
tar cf "$imgfile" "$outfile"
-if [ "$(echo "nativedisk; source '(usb0)/$outfile';" | "${grubshell}" --qemu-opts="-device ich9-usb-uhci1 -drive id=my_usb_disk,file=$imgfile,if=none -device usb-storage,drive=my_usb_disk" | tail -n 1)" != "Hello World" ]; then
+v=$(echo "nativedisk; source '(usb0)/$outfile';" |
+ "${grubshell}" --qemu-opts="-device ich9-usb-uhci1
+ -drive id=my_usb_disk,file=$imgfile,if=none
+ -device usb-storage,drive=my_usb_disk" |
+ tail -n 1)
+if [ "$v" != "Hello World" ]; then
rm "$imgfile"
rm "$outfile"
exit 1
exit 77
fi
-if [ "$(echo hello | "${grubshell}" --mkrescue-arg=--compress=xz)" != "Hello World" ]; then
+v=$(echo hello | "${grubshell}" --mkrescue-arg=--compress=xz)
+if [ "$v" != "Hello World" ]; then
exit 1
fi