From b1c10101c322d3baf90914715fe08b87e0c223bd Mon Sep 17 00:00:00 2001 From: wheaney <42350981+wheaney@users.noreply.github.com> Date: Tue, 20 Aug 2024 10:42:41 -0700 Subject: [PATCH] Fix the uninstall's script removal of udev files --- bin/xr_driver_uninstall | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/bin/xr_driver_uninstall b/bin/xr_driver_uninstall index fc1b4eb..1eed6de 100755 --- a/bin/xr_driver_uninstall +++ b/bin/xr_driver_uninstall @@ -55,15 +55,11 @@ fi rm -f $SYSTEMD_USER_DIR/xr-driver.service UDEV_RULES_DIR="/usr/lib/udev/rules.d" -if [ -f /etc/os-release ]; then - . /etc/os-release - if [ "$ID" == "steamos" ]; then - UDEV_RULES_DIR="/etc/udev/rules.d" - fi -fi +ALT_UDEV_RULES_DIR="/etc/udev/rules.d" -[ "$for_install" -eq 0 ] && echo "Removing the udev rules from ${UDEV_RULES_DIR}" -sudo rm $UDEV_RULES_DIR/70-*-xr.rules +[ "$for_install" -eq 0 ] && echo "Removing the udev rules from ${UDEV_RULES_DIR} or ${ALT_UDEV_RULES_DIR}" +sudo rm $UDEV_RULES_DIR/70-*-xr.rules > /dev/null 2>&1 || true +sudo rm $ALT_UDEV_RULES_DIR/70-*-xr.rules > /dev/null 2>&1 || true if [ "$for_install" -eq 0 ]; then echo "Removing installed files from $STATE_DIR, $CONFIG_DIR, $DATA_DIR, and $BIN_DIR"