refactor(klipper): full refactor of klipper install/remove part (#264)

This commit is contained in:
th33xitus
2022-11-13 15:51:22 +01:00
committed by GitHub
parent 54be7e4e21
commit 67afa26ed7
3 changed files with 288 additions and 344 deletions

View File

@@ -47,7 +47,7 @@ function install_menu() {
read -p "${cyan}####### Perform action:${white} " action
case "${action}" in
1)
do_action "select_klipper_python_version" "install_ui";;
do_action "start_klipper_setup" "install_ui";;
2)
do_action "moonraker_setup_dialog" "install_ui";;
3)
@@ -77,33 +77,3 @@ function install_menu() {
done
install_menu
}
function select_klipper_python_version() {
top_border
echo -e "| Please select the preferred Python version. | "
echo -e "| The recommended version is Python 2.7. | "
blank_line
echo -e "| Installing Klipper with Python 3 is officially not | "
echo -e "| recommended and should be considered as experimental. | "
hr
echo -e "| 1) [Python 2.7] (recommended) | "
echo -e "| 2) [Python 3.x] ${yellow}(experimental)${white} | "
back_footer
while true; do
read -p "${cyan}###### Select Python version:${white} " action
case "${action}" in
1)
select_msg "Python 2.7"
klipper_setup_dialog "python2"
break;;
2)
select_msg "Python 3.x"
klipper_setup_dialog "python3"
break;;
B|b)
clear; install_menu; break;;
*)
error_msg "Invalid Input!\n";;
esac
done
}