#!/bin/bash # Bash Menu Script Example PORT=${2:-10022} echo Port $PORT PS3='Please enter your starting option: ' options=("with root bash" "normal" "Quit") select opt in "${options[@]}" do case $opt in "with root bash") echo "you chose root bash" # start with root bash qemu-system-arm -kernel actual-kernel -cpu arm1176 -m 256 -M versatilepb -no-reboot -serial stdio -append "root=/dev/sda2 panic=1 rootfstype=ext4 rw init=/bin/bash" -hda $1 -net user,hostfwd=tcp::$PORT-:22 -net nic ;; "normal") echo "you chose normal" # start normal qemu-system-arm -kernel actual-kernel -cpu arm1176 -m 256 -M versatilepb -no-reboot -serial stdio -append "root=/dev/sda2 panic=1 rootfstype=ext4 rw" -hda $1 -net user,hostfwd=tcp::$PORT-:22 -net nic ;; "Quit") break ;; *) echo invalid option;; esac done