Ask to re-run a failed step
This commit is contained in:
parent
9b7374f768
commit
c5bae37f33
32
install.sh
32
install.sh
@ -55,18 +55,28 @@ done
|
||||
|
||||
for flavour in flavours/*.flavour
|
||||
do
|
||||
echo -n "=> Do you want to run flavour '$flavour'? (y/N) "
|
||||
read answer
|
||||
# in any case, run it once
|
||||
rerun=1
|
||||
|
||||
if [ "$answer" == "y" ] || [ "$answer" == "Y" ]; then
|
||||
echo "=> Running flavour '$flavour'..."
|
||||
pushd $flavour
|
||||
source ./install.sh
|
||||
if [ "$amf_return" -ne 0 ]; then
|
||||
echo "=> Flavour failed. :("
|
||||
fi
|
||||
popd
|
||||
fi
|
||||
while [ $rerun ]; do
|
||||
echo -n "=> Do you want to run flavour '$flavour'? (y/N) "
|
||||
read answer
|
||||
|
||||
if [ "$answer" == "y" ] || [ "$answer" == "Y" ]; then
|
||||
echo "=> Running flavour '$flavour'..."
|
||||
pushd $flavour
|
||||
source ./install.sh
|
||||
rerun=0;
|
||||
if [ "$amf_return" -ne 0 ]; then
|
||||
echo "=> Flavour failed. :( Rerun? (Y/n) "
|
||||
read answer
|
||||
if [ "$answer" == "y" ] || [ "$answer" == "Y" ]; then
|
||||
rerun=1;
|
||||
fi
|
||||
fi
|
||||
popd
|
||||
fi
|
||||
done
|
||||
done
|
||||
|
||||
echo -n "=> Finished \o/ reboot now? (Y/n) "
|
||||
|
Loading…
Reference in New Issue
Block a user