mirror of
https://github.com/dw-0/kiauh.git
synced 2025-12-15 19:44:29 +05:00
fix: try to fix a bug where the script errors out, telling that there is already a moonraker service installed but actually there isn't
This commit is contained in:
@@ -46,12 +46,12 @@ moonraker_setup_dialog(){
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
### check for existing moonraker service installations
|
### check for existing moonraker service installations
|
||||||
if [ "$(systemctl list-units --full -all -t service --no-legend | grep -F "moonraker.service")" ] || [ "$(systemctl list-units --full -all -t service --no-legend | grep -E "moonraker-[[:digit:]].service")" ]; then
|
if ls /etc/systemd/system/moonraker*.service 2>/dev/null 1>&2; then
|
||||||
ERROR_MSG="At least one Moonraker service is already installed!" && return 0
|
ERROR_MSG="At least one Moonraker service is already installed!" && return 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
### check for existing klipper service installations
|
### check for existing klipper service installations
|
||||||
if [ ! "$(systemctl list-units --full -all -t service --no-legend | grep -F "klipper.service")" ] && [ ! "$(systemctl list-units --full -all -t service --no-legend | grep -E "klipper-[[:digit:]].service")" ]; then
|
if ! ls /etc/systemd/system/klipper*.service 2>/dev/null 1>&2; then
|
||||||
ERROR_MSG="Klipper service not found, please install Klipper first!" && return 0
|
ERROR_MSG="Klipper service not found, please install Klipper first!" && return 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user