Simplify control flow
This commit is contained in:
parent
d5f998ee8f
commit
6c1aebcbde
1 changed files with 3 additions and 4 deletions
|
@ -38,18 +38,17 @@ while true; do
|
||||||
read -r r
|
read -r r
|
||||||
if [ "${r}" = "1" ]; then
|
if [ "${r}" = "1" ]; then
|
||||||
erase "${gitdir}"
|
erase "${gitdir}"
|
||||||
exit
|
|
||||||
elif [ "${r}" = "2" ]; then
|
elif [ "${r}" = "2" ]; then
|
||||||
erase "${installdir}"
|
erase "${installdir}"
|
||||||
exit
|
|
||||||
elif [ "${r}" = "3" ]; then
|
elif [ "${r}" = "3" ]; then
|
||||||
erase "${gitdir}"
|
erase "${gitdir}"
|
||||||
erase "${installdir}"
|
erase "${installdir}"
|
||||||
exit
|
|
||||||
elif [ "${r}" = "4" ]; then
|
elif [ "${r}" = "4" ]; then
|
||||||
exit
|
break
|
||||||
else
|
else
|
||||||
printf "%s is not a valid option\n" "${r}"
|
printf "%s is not a valid option\n" "${r}"
|
||||||
printf "1-4: "
|
printf "1-4: "
|
||||||
|
continue
|
||||||
fi
|
fi
|
||||||
|
exit
|
||||||
done
|
done
|
||||||
|
|
Loading…
Reference in a new issue