From 8ad7f5d47c81e0f829c003039e3e5dc058c9f754 Mon Sep 17 00:00:00 2001 From: th33xitus Date: Thu, 28 Jan 2021 16:21:24 +0100 Subject: [PATCH] fix: remove update manager question. thanks to the recent changes to the update manager, mainsail and fluidd can be supported at the same time. --- scripts/install_klipper_webui.sh | 64 +------------------------------- 1 file changed, 1 insertion(+), 63 deletions(-) diff --git a/scripts/install_klipper_webui.sh b/scripts/install_klipper_webui.sh index f40d9cb..b4f8a50 100755 --- a/scripts/install_klipper_webui.sh +++ b/scripts/install_klipper_webui.sh @@ -57,9 +57,6 @@ install_mainsail(){ ### ask user to install the recommended webinterface macros get_user_selection_kiauh_macros - ### ask user to enable the moonraker update manager - enable_update_manager "mainsail" - ### creating the mainsail nginx cfg set_nginx_cfg "mainsail" @@ -86,9 +83,6 @@ install_fluidd(){ ### ask user to install the recommended webinterface macros get_user_selection_kiauh_macros - ### ask user to enable the moonraker update manager - enable_update_manager "fluidd" - ### creating the fluidd nginx cfg set_nginx_cfg "fluidd" @@ -287,60 +281,4 @@ fluidd_setup(){ status_msg "Remove downloaded archive ..." rm -rf *.zip && ok_msg "Done!" && ok_msg "Fluidd installation complete!" echo -} - -enable_update_manager(){ - source_kiauh_ini - ### ask user if he wants to enable the moonraker update manager - while true; do - echo - top_border - echo -e "| Do you want to enable the Moonraker Update Manager | " - echo -e "| for the selected webinterface? | " - hr - echo -e "| ${yellow}Please note:${default} | " - echo -e "| Entries for an already enabled update manager will be | " - echo -e "| overwritten if you decide to choose 'Yes'! | " - bottom_border - echo - read -p "${cyan}###### Enable Update Manager? (Y/n):${default} " yn - case "$yn" in - Y|y|Yes|yes|"") - echo -e "###### > Yes" - if [ $1 = "mainsail" ]; then - MOONRAKER_UPDATE_MANAGER="[update_manager]\nclient_repo: meteyou/mainsail\nclient_path: /home/${USER}/mainsail" - elif [ $1 = "fluidd" ]; then - MOONRAKER_UPDATE_MANAGER="[update_manager]\nclient_repo: cadriel/fluidd\nclient_path: /home/${USER}/fluidd" - else - unset MOONRAKER_UPDATE_MANAGER - fi - ### handle single moonraker install - if [ -f /etc/systemd/system/moonraker.service ]; then - ### delete existing entries - sed -i "/update_manager/d" $klipper_cfg_loc/moonraker.conf - sed -i "/client_repo/d" $klipper_cfg_loc/moonraker.conf - sed -i "/client_path/d" $klipper_cfg_loc/moonraker.conf - echo -e $MOONRAKER_UPDATE_MANAGER >> $klipper_cfg_loc/moonraker.conf - fi - ### handle multi moonraker installs - if ls /etc/systemd/system/moonraker-*.service 2>/dev/null 1>&2; then - for moonraker_conf in $(find $klipper_cfg_loc/printer_*/moonraker.conf); do - ### delete existing entries - sed -i "/update_manager/d" $moonraker_conf - sed -i "/client_repo/d" $moonraker_conf - sed -i "/client_path/d" $moonraker_conf - echo -e $MOONRAKER_UPDATE_MANAGER >> $moonraker_conf - done - fi - moonraker_service "restart" - break;; - N|n|No|no) - echo -e "###### > No" - unset MOONRAKER_UPDATE_MANAGER - break;; - *) - print_unkown_cmd - print_msg && clear_msg;; - esac - done -} +} \ No newline at end of file