Commit fea6c5fb authored by Alex's avatar Alex
Browse files

Merged in t3r4n/magic-lantern/qemu_install_improvement (pull request #892)

Option to rename or delete existing QEMU directory during installation

--HG--
branch : qemu
parent 0a7e1da6cdb5
......@@ -318,9 +318,24 @@ echo "*** Setting up QEMU in $(pwd)..."
echo
if [ -d $QEMU_NAME ]; then
DATE=`date '+%Y-%m-%d-%H-%M-%S'`
echo "*** Directory $(pwd)/$QEMU_NAME already exists."
echo "*** To reinstall, please rename or delete it, then run this script again."
exit 1
echo "*** You can enter \"D\" (uppercase!) now to delete the directory automatically"
echo "*** or \"R\"|\"r\" to rename it to $(pwd)/$QEMU_NAME-$DATE."
echo "*** Everything else will cancel the operation."
read answer
case "$answer" in
D)
rm -Rf $QEMU_NAME
;;
R|r)
mv $QEMU_NAME $QEMU_NAME-$DATE
;;
*)
exit 1
;;
esac
fi
# get qemu
......@@ -328,7 +343,6 @@ wget -q --show-progress --progress=dot:giga -c http://wiki.qemu-project.org/down
echo
tar jxf $QEMU_NAME.tar.bz2
echo
# initialize a git repo, to make it easy to track changes to QEMU source
cd $QEMU_NAME
if [ ! -d .git ]; then
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment